--- [.process_orig]process.xs	Wed Aug 20 17:02:17 2008
+++ [.process]process.xs	Tue Aug 19 08:34:10 2008
@@ -13,6 +13,8 @@
  * 1.01 25-Nov-1997 Dan Sugalski <sugalskd@osshe.edu>
  *      Merged VMS::ProcInfo into VMS::Process
  *
+ * 1.02 18-Aug-2008 throwing some errors (fussier C compiler)
+ *
  */
 
 #ifdef __cplusplus
@@ -72,9 +74,9 @@
 #define bit_test(HVPointer, BitToCheck, HVEntryName, EncodedMask) \
 { \
     if ((EncodedMask) && (BitToCheck)) \
-    hv_store((HVPointer), (HVEntryName), strlen((HVEntryName)), &sv_yes, 0); \
+    hv_store((HVPointer), (HVEntryName), strlen((HVEntryName)), &PL_sv_yes, 0); \
     else \
-    hv_store((HVPointer), (HVEntryName), strlen((HVEntryName)), &sv_no, 0);}   
+    hv_store((HVPointer), (HVEntryName), strlen((HVEntryName)), &PL_sv_no, 0);}   
 
 struct ProcessID {
   char *ProcListName; /* Pointer to the item name */
@@ -593,22 +595,22 @@
 
       NameSV = *hv_fetch((HV *)RealSV, "NAME", 4, 0);
       ValueSV = *hv_fetch((HV *)RealSV, "VALUE", 5, 0);
-      ItemType = get_item_type(SvPV(NameSV, na));
-      ItemPScanVal = get_item_pscan_val(SvPV(NameSV, na));
+      ItemType = get_item_type(SvPV(NameSV, PL_na));
+      ItemPScanVal = get_item_pscan_val(SvPV(NameSV, PL_na));
       FlagsVal = 0; /* By default we have no flags */
       /* If we've got a comparison op, get its flags and see what we get */
       if (hv_exists_ent((HV *)RealSV, ComparisonConstSV, 0)) {
         ComparisonSV = *hv_fetch((HV *)RealSV, "COMPARISON", 10, 0);
-        FlagsVal = FlagsVal | get_comparison_bits(SvPV(ComparisonSV, na));
+        FlagsVal = FlagsVal | get_comparison_bits(SvPV(ComparisonSV, PL_na));
       }
       /* If we've got a modifier op, get its flags and see what we get */
       if (hv_exists_ent((HV *)RealSV, ModifierConstSV, 0)) {
         ModifierSV = *hv_fetch((HV *)RealSV, "MODIFIER", 8, 0);
-        FlagsVal = FlagsVal | get_modifier_bits(SvPV(ModifierSV, na));
+        FlagsVal = FlagsVal | get_modifier_bits(SvPV(ModifierSV, PL_na));
       }
       switch(ItemType) {
       case IS_STRING:
-        TempStringPointer = SvPV(ValueSV, na);
+        TempStringPointer = SvPV(ValueSV, PL_na);
         init_bufitemlist(&ProcScanItemList[i], strlen(TempStringPointer),
                          ItemPScanVal, TempStringPointer, FlagsVal);
         break;
@@ -617,7 +619,7 @@
                          FlagsVal);
         break;
       case IS_ENUM:
-        TempStringPointer = SvPV(ValueSV, na);
+        TempStringPointer = SvPV(ValueSV, PL_na);
         init_lititemlist(&ProcScanItemList[i], ItemPScanVal,
                          de_enum(ItemPScanVal, TempStringPointer),
                          FlagsVal);
@@ -657,7 +659,7 @@
     }
   } else {
     SETERRNO(EVMSERR, status);
-    ST(0) = &sv_undef;
+    ST(0) = &PL_sv_undef;
   }
 }
 
@@ -670,9 +672,9 @@
   status = sys$suspnd(&pid, NULL, NULL);
   if (status != SS$_NORMAL) {
     SETERRNO(EVMSERR, status);
-    ST(0) = &sv_no;
+    ST(0) = &PL_sv_no;
   } else {
-    ST(0) = &sv_yes;
+    ST(0) = &PL_sv_yes;
   }
 }
 
@@ -685,9 +687,9 @@
   status = sys$resume(&pid, NULL);
   if (status != SS$_NORMAL) {
     SETERRNO(EVMSERR, status);
-    ST(0) = &sv_no;
+    ST(0) = &PL_sv_no;
   } else {
-    ST(0) = &sv_yes;
+    ST(0) = &PL_sv_yes;
   }
 }
 
@@ -700,9 +702,9 @@
   status = sys$delprc(&pid, NULL);
   if (status != SS$_NORMAL) {
     SETERRNO(EVMSERR, status);
-    ST(0) = &sv_no;
+    ST(0) = &PL_sv_no;
   } else {
-    ST(0) = &sv_yes;
+    ST(0) = &PL_sv_yes;
   }
 }
 
@@ -717,9 +719,9 @@
   status = sys$setpri(&pid, NULL, newpriority, &OldPriority, NULL, NULL);
   if (status != SS$_NORMAL) {
     SETERRNO(EVMSERR, status);
-    ST(0) = &sv_no;
+    ST(0) = &PL_sv_no;
   } else {
-    ST(0) = &sv_yes;
+    ST(0) = &PL_sv_yes;
   }
 }
 
@@ -765,7 +767,7 @@
   char QuadWordString[65];
   
   for (i = 0; ProcInfoList[i].ProcInfoName; i++) {
-    if (strEQ(ProcInfoList[i].ProcInfoName, SvPV(infoname, na))) {
+    if (strEQ(ProcInfoList[i].ProcInfoName, SvPV(infoname, PL_na))) {
       break;
     }
   }
@@ -773,7 +775,7 @@
   /* Did we find a match? If not, complain and exit */
   if (ProcInfoList[i].ProcInfoName == NULL) {
     warn("Invalid proc info item");
-    ST(0) = &sv_undef;
+    ST(0) = &PL_sv_undef;
   } else {
     /* allocate our item list */
     ITMLST OneItem[2];
@@ -815,7 +817,7 @@
       break;
     default:
       warn("Unknown item return type");
-      ST(0) = &sv_undef;
+      ST(0) = &PL_sv_undef;
       return;
     }
     
@@ -854,14 +856,14 @@
         ST(0) =  sv_2mortal(newSViv(ReturnLongWordBuffer));
         break;
       default:
-        ST(0) = &sv_undef;
+        ST(0) = &PL_sv_undef;
         break;
       }
 
       
     } else {
       SETERRNO(EVMSERR, status);
-      ST(0) = &sv_undef;
+      ST(0) = &PL_sv_undef;
       /* free up the buffer if we were looking for a string */
       if (ProcInfoList[i].ReturnType == IS_STRING)
         free(ReturnStringBuffer);
@@ -975,7 +977,7 @@
      } else {
        /* I think we failed */
        SETERRNO(EVMSERR, status);
-       ST(0) = &sv_undef;
+       ST(0) = &PL_sv_undef;
      }
 
      /* Free up our allocated memory */
@@ -1096,6 +1098,6 @@
   if (AllPurposeHV) {
     ST(0) = (SV *)AllPurposeHV;
   } else {
-    ST(0) = &sv_undef;
+    ST(0) = &PL_sv_undef;
   }
 }
