jfclere     2002/09/17 05:25:50

  Modified:    daemon/src/native/unix/native arguments.c location.c
                        replace.c
  Log:
  Arrange Java style comments - My compiler does like those -
  
  Revision  Changes    Path
  1.5       +15 -15    
jakarta-commons-sandbox/daemon/src/native/unix/native/arguments.c
  
  Index: arguments.c
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/native/arguments.c,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- arguments.c       13 Mar 2002 23:09:48 -0000      1.4
  +++ arguments.c       17 Sep 2002 12:25:50 -0000      1.5
  @@ -78,21 +78,21 @@
   
       /* Create the default command line arguments */
       args=(arg_data *)malloc(sizeof(arg_data));
  -    args->pidf="/var/run/jsvc.pid"; // The default PID file
  -    args->user=NULL;            // No user switching by default
  -    args->dtch=true;            // Do detach from parent
  -    args->vers=false;           // Don't display version
  -    args->help=false;           // Don't display help
  -    args->chck=false;           // Don't do a check-only startup
  -    args->install=false;        // Don't install as a service
  -    args->remove=false;         // Don't remove the installed service
  -    args->service=false;        // Don't run as a service
  -    args->name=NULL;            // No VM version name
  -    args->home=NULL;            // No default JAVA_HOME
  -    args->onum=0;               // Zero arguments, but let's have some room
  +    args->pidf="/var/run/jsvc.pid"; /* The default PID file */
  +    args->user=NULL;            /* No user switching by default */
  +    args->dtch=true;            /* Do detach from parent */
  +    args->vers=false;           /* Don't display version */
  +    args->help=false;           /* Don't display help */
  +    args->chck=false;           /* Don't do a check-only startup */
  +    args->install=false;        /* Don't install as a service */
  +    args->remove=false;         /* Don't remove the installed service */
  +    args->service=false;        /* Don't run as a service */
  +    args->name=NULL;            /* No VM version name */
  +    args->home=NULL;            /* No default JAVA_HOME */
  +    args->onum=0;               /* Zero arguments, but let's have some room */
       args->opts=(char **)malloc(argc*sizeof(char *));
  -    args->clas=NULL;            // No class predefined
  -    args->anum=0;               // Zero class specific arguments but make room
  +    args->clas=NULL;            /* No class predefined */
  +    args->anum=0;               /* Zero class specific arguments but make room*/
       args->args=(char **)malloc(argc*sizeof(char *));
   
       /* Set up the command name */
  
  
  
  1.2       +17 -17    jakarta-commons-sandbox/daemon/src/native/unix/native/location.c
  
  Index: location.c
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/native/location.c,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- location.c        18 Feb 2002 21:15:42 -0000      1.1
  +++ location.c        17 Sep 2002 12:25:50 -0000      1.2
  @@ -86,8 +86,8 @@
      we're going to look thru the "configured" VMs (from lod_cfgvm) lying
      somewhere around JAVA_HOME. (Only two, I'm happy) */
   char *location_jvm_cfg[] = {
  -    "$JAVA_HOME/jre/lib/jvm.cfg", // JDK
  -    "$JAVA_HOME/lib/jvm.cfg",     // JRE
  +    "$JAVA_HOME/jre/lib/jvm.cfg", /* JDK */
  +    "$JAVA_HOME/lib/jvm.cfg",     /* JRE */
       NULL,
   };
   
  @@ -97,18 +97,18 @@
   #if defined(OS_DARWIN)
       "$JAVA_HOME/../Libraries/libjvm.dylib",
   #elif defined(OS_CYGWIN)
  -    "$JAVA_HOME/jre/bin/classic/jvm.dll",           // Sun JDK 1.3
  +    "$JAVA_HOME/jre/bin/classic/jvm.dll",           /* Sun JDK 1.3 */
   #elif defined(OS_LINUX) || defined(OS_SOLARIS) || defined(OS_BSD)
  -    "$JAVA_HOME/jre/lib/" CPU "/classic/libjvm.so", // Sun JDK 1.2
  -    "$JAVA_HOME/jre/lib/" CPU "/client/libjvm.so",  // Sun JDK 1.3
  -    "$JAVA_HOME/jre/lib/" CPU "/libjvm.so",         // Sun JDK
  -    "$JAVA_HOME/lib/" CPU "/classic/libjvm.so",     // Sun JRE 1.2
  -    "$JAVA_HOME/lib/" CPU "/client/libjvm.so",      // Sun JRE 1.3
  -    "$JAVA_HOME/lib/" CPU "/libjvm.so",             // Sun JRE
  -    "$JAVA_HOME/jre/bin/" CPU "/classic/libjvm.so", // IBM JDK 1.3
  -    "$JAVA_HOME/jre/bin/" CPU "/libjvm.so",         // IBM JDK
  -    "$JAVA_HOME/bin/" CPU "/classic/libjvm.so",     // IBM JRE 1.3
  -    "$JAVA_HOME/bin/" CPU "/libjvm.so",             // IBM JRE
  +    "$JAVA_HOME/jre/lib/" CPU "/classic/libjvm.so", /* Sun JDK 1.2 */
  +    "$JAVA_HOME/jre/lib/" CPU "/client/libjvm.so",  /* Sun JDK 1.3 */
  +    "$JAVA_HOME/jre/lib/" CPU "/libjvm.so",         /* Sun JDK */
  +    "$JAVA_HOME/lib/" CPU "/classic/libjvm.so",     /* Sun JRE 1.2 */
  +    "$JAVA_HOME/lib/" CPU "/client/libjvm.so",      /* Sun JRE 1.3 */
  +    "$JAVA_HOME/lib/" CPU "/libjvm.so",             /* Sun JRE */
  +    "$JAVA_HOME/jre/bin/" CPU "/classic/libjvm.so", /* IBM JDK 1.3 */
  +    "$JAVA_HOME/jre/bin/" CPU "/libjvm.so",         /* IBM JDK */
  +    "$JAVA_HOME/bin/" CPU "/classic/libjvm.so",     /* IBM JRE 1.3 */
  +    "$JAVA_HOME/bin/" CPU "/libjvm.so",             /* IBM JRE */
       /* Those are "weirdos: if we got here, we're probably in troubles and
          we're not going to find anything, but hope never dies... */
       "$JAVA_HOME/jre/lib/classic/libjvm.so",
  @@ -134,10 +134,10 @@
   #if defined(OS_DARWIN)
       "$JAVA_HOME/../Libraries/lib$VM_NAME.dylib",
   #elif defined(OS_CYGWIN)
  -    "$JAVA_HOME/jre/bin/$VM_NAME/jvm.dll",          // Sun JDK 1.3
  +    "$JAVA_HOME/jre/bin/$VM_NAME/jvm.dll",          /* Sun JDK 1.3 */
   #elif defined(OS_LINUX) || defined(OS_SOLARIS) || defined(OS_BSD)
  -    "$JAVA_HOME/jre/lib/" CPU "/$VM_NAME/libjvm.so",// Sun JDK 1.3
  -    "$JAVA_HOME/lib/" CPU "/$VM_NAME/libjvm.so",    // Sun JRE 1.3
  +    "$JAVA_HOME/jre/lib/" CPU "/$VM_NAME/libjvm.so",/* Sun JDK 1.3 */
  +    "$JAVA_HOME/lib/" CPU "/$VM_NAME/libjvm.so",    /* Sun JRE 1.3 */
   #endif
       NULL,
   };
  
  
  
  1.2       +11 -7     jakarta-commons-sandbox/daemon/src/native/unix/native/replace.c
  
  Index: replace.c
  ===================================================================
  RCS file: /home/cvs/jakarta-commons-sandbox/daemon/src/native/unix/native/replace.c,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- replace.c 18 Feb 2002 21:15:42 -0000      1.1
  +++ replace.c 17 Sep 2002 12:25:50 -0000      1.2
  @@ -112,7 +112,7 @@
          and of how many bytes we need to shift the data */
       shift=rlen-mlen;
       nlen=olen+(shift*count);
  -    // printf("Count=%d Shift= %d OLen=%d NLen=%d\n",count,shift,olen,nlen);
  +    /* printf("Count=%d Shift= %d OLen=%d NLen=%d\n",count,shift,olen,nlen); */
   
       /* Check if we have enough size in the buffer */
       if (nlen>=len) return(nlen+1);
  @@ -126,22 +126,26 @@
           /* If shift is > 0 we need to move data from right to left */
           if (shift>0) {
               for (x=(strlen(tmp)+shift);x>shift;x--) {
  -                // printf("src %c(%d) dst %c(%d)\n",
  -                //        tmp[x-shift],tmp[x-shift],tmp[x],tmp[x]);
  +                /*
  +                printf("src %c(%d) dst %c(%d)\n",
  +                        tmp[x-shift],tmp[x-shift],tmp[x],tmp[x]);
  +                 */
                   tmp[x]=tmp[x-shift];
               }
           /* If shift is < 0 we need to move data from left to right */
           } else if (shift<0) {
               for (x=mlen;x<strlen(tmp)-shift;x++) {
  -                // printf("src %c(%d) dst %c(%d)\n",
  -                //        tmp[x],tmp[x],tmp[x+shift],tmp[x+shift]);
  +                /*
  +                   printf("src %c(%d) dst %c(%d)\n",
  +                          tmp[x],tmp[x],tmp[x+shift],tmp[x+shift]);
  +                 */
                   tmp[x+shift]=tmp[x];
               }
           }
           /* If shift is = 0 we don't have to shift data */
           strncpy(tmp,rpl,rlen);
           tmp+=rlen;
  -        // printf("\"%s\"\n",tmp);
  +        /* printf("\"%s\"\n",tmp); */
       }
       return(0);
   }
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to