[BACK]Return to wordexp.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / lib / libc / gen

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/lib/libc/gen/wordexp.c between version 1.2 and 1.3

version 1.2, 2005/11/29 03:11:59 version 1.3, 2009/02/12 04:10:52
Line 94  we_askshell(const char *words, wordexp_t
Line 94  we_askshell(const char *words, wordexp_t
         int pdes[2];                    /* Pipe to child */          int pdes[2];                    /* Pipe to child */
         size_t nwords, nbytes;          /* Number of words, bytes from child */          size_t nwords, nbytes;          /* Number of words, bytes from child */
         int i;                          /* Handy integer */          int i;                          /* Handy integer */
           unsigned int ui;                /* For array iteration */
         size_t sofs;                    /* Offset into we->we_strings */          size_t sofs;                    /* Offset into we->we_strings */
         size_t vofs;                    /* Offset into we->we_wordv */          size_t vofs;                    /* Offset into we->we_wordv */
         pid_t pid;                      /* Process ID of child */          pid_t pid;                      /* Process ID of child */
Line 204  we_askshell(const char *words, wordexp_t
Line 205  we_askshell(const char *words, wordexp_t
                 waitpid(pid, &status, 0);                  waitpid(pid, &status, 0);
                 return (WRDE_NOSPACE);                  return (WRDE_NOSPACE);
         }          }
         for (i = 0; i < vofs; i++)          for (ui = 0; ui < vofs; ui++)
                 if (we->we_wordv[i] != NULL)                  if (we->we_wordv[ui] != NULL)
                         we->we_wordv[i] += nstrings - we->we_strings;                          we->we_wordv[ui] += nstrings - we->we_strings;
         we->we_strings = nstrings;          we->we_strings = nstrings;
   
         if (fread(we->we_strings + sofs, sizeof(char), nbytes, fp) != nbytes) {          if (fread(we->we_strings + sofs, sizeof(char), nbytes, fp) != nbytes) {

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

CVSweb <webmaster@jp.NetBSD.org>