pidgone() is only used in util.c, so it can be static.
Nicholas Clark [Wed, 26 Nov 2008 21:33:54 +0000 (21:33 +0000)]
p4raw-id: //depot/perl@34932

embed.fnc
embed.h
proto.h
util.c

index 8495b71..c1d01e3 100644 (file)
--- a/embed.fnc
+++ b/embed.fnc
@@ -706,8 +706,8 @@ Apd |void   |require_pv     |NN const char* pv
 Apd    |void   |pack_cat       |NN SV *cat|NN const char *pat|NN const char *patend \
                                |NN SV **beglist|NN SV **endlist|NN SV ***next_in_list|U32 flags
 Apd    |void   |packlist       |NN SV *cat|NN const char *pat|NN const char *patend|NN SV **beglist|NN SV **endlist
-#ifdef PERL_USES_PL_PIDSTATUS
-p      |void   |pidgone        |Pid_t pid|int status
+#if defined(PERL_USES_PL_PIDSTATUS) && defined(PERL_IN_UTIL_C)
+s      |void   |pidgone        |Pid_t pid|int status
 #endif
 Ap     |void   |pmflag         |NN U32* pmfl|int ch
 p      |OP*    |pmruntime      |NN OP *o|NN OP *expr|bool isreg
diff --git a/embed.h b/embed.h
index 9b3c4d7..6309734 100644 (file)
--- a/embed.h
+++ b/embed.h
 #define require_pv             Perl_require_pv
 #define pack_cat               Perl_pack_cat
 #define packlist               Perl_packlist
-#ifdef PERL_USES_PL_PIDSTATUS
+#if defined(PERL_USES_PL_PIDSTATUS) && defined(PERL_IN_UTIL_C)
 #ifdef PERL_CORE
-#define pidgone                        Perl_pidgone
+#define pidgone                        S_pidgone
 #endif
 #endif
 #define pmflag                 Perl_pmflag
 #define require_pv(a)          Perl_require_pv(aTHX_ a)
 #define pack_cat(a,b,c,d,e,f,g)        Perl_pack_cat(aTHX_ a,b,c,d,e,f,g)
 #define packlist(a,b,c,d,e)    Perl_packlist(aTHX_ a,b,c,d,e)
-#ifdef PERL_USES_PL_PIDSTATUS
+#if defined(PERL_USES_PL_PIDSTATUS) && defined(PERL_IN_UTIL_C)
 #ifdef PERL_CORE
-#define pidgone(a,b)           Perl_pidgone(aTHX_ a,b)
+#define pidgone(a,b)           S_pidgone(aTHX_ a,b)
 #endif
 #endif
 #define pmflag(a,b)            Perl_pmflag(aTHX_ a,b)
diff --git a/proto.h b/proto.h
index 0e43560..42377d3 100644 (file)
--- a/proto.h
+++ b/proto.h
@@ -2497,8 +2497,8 @@ PERL_CALLCONV void        Perl_packlist(pTHX_ SV *cat, const char *pat, const char *pat
 #define PERL_ARGS_ASSERT_PACKLIST      \
        assert(cat); assert(pat); assert(patend); assert(beglist); assert(endlist)
 
-#ifdef PERL_USES_PL_PIDSTATUS
-PERL_CALLCONV void     Perl_pidgone(pTHX_ Pid_t pid, int status);
+#if defined(PERL_USES_PL_PIDSTATUS) && defined(PERL_IN_UTIL_C)
+STATIC void    S_pidgone(pTHX_ Pid_t pid, int status);
 #endif
 PERL_CALLCONV void     Perl_pmflag(pTHX_ U32* pmfl, int ch)
                        __attribute__nonnull__(pTHX_1);
diff --git a/util.c b/util.c
index 0c15c56..0287d34 100644 (file)
--- a/util.c
+++ b/util.c
@@ -3020,7 +3020,7 @@ Perl_wait4pid(pTHX_ Pid_t pid, int *statusp, int flags)
 
 #ifdef PERL_USES_PL_PIDSTATUS
 void
-Perl_pidgone(pTHX_ Pid_t pid, int status)
+S_pidgone(pTHX_ Pid_t pid, int status)
 {
     register SV *sv;