[BACK]Return to inp.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / patch

Diff for /src/usr.bin/patch/inp.c between version 1.37 and 1.38

version 1.37, 2013/11/26 13:19:07 version 1.38, 2014/10/08 04:06:23
Line 111 
Line 111 
         size_t  new_size;          size_t  new_size;
   
         new_size = *lines_allocated * 3 / 2;          new_size = *lines_allocated * 3 / 2;
         p = realloc(i_ptr, (new_size + 2) * sizeof(char *));          p = reallocarray(i_ptr, new_size + 2, sizeof(char *));
         if (p == NULL) {        /* shucks, it was a near thing */          if (p == NULL) {        /* shucks, it was a near thing */
                 munmap(i_womp, i_size);                  munmap(i_womp, i_size);
                 i_womp = NULL;                  i_womp = NULL;

Legend:
Removed from v.1.37  
changed lines
  Added in v.1.38