/[pcre]/code/branches/pcre16/pcre_compile.c
ViewVC logotype

Diff of /code/branches/pcre16/pcre_compile.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 818 by ph10, Thu Dec 22 20:11:31 2011 UTC revision 819 by zherczeg, Thu Dec 22 23:10:09 2011 UTC
# Line 685  if (cd->workspace_size >= COMPILE_WORK_S Line 685  if (cd->workspace_size >= COMPILE_WORK_S
685      newsize - cd->workspace_size < WORK_SIZE_SAFETY_MARGIN)      newsize - cd->workspace_size < WORK_SIZE_SAFETY_MARGIN)
686   return ERR72;   return ERR72;
687    
688  newspace = (PUBL(malloc))(newsize * sizeof(pcre_uchar));  newspace = (PUBL(malloc))(IN_UCHARS(newsize));
689  if (newspace == NULL) return ERR21;  if (newspace == NULL) return ERR21;
690  memcpy(newspace, cd->start_workspace, cd->workspace_size * sizeof(pcre_uchar));  memcpy(newspace, cd->start_workspace, cd->workspace_size * sizeof(pcre_uchar));
691  cd->hwm = (pcre_uchar *)newspace + (cd->hwm - cd->start_workspace);  cd->hwm = (pcre_uchar *)newspace + (cd->hwm - cd->start_workspace);

Legend:
Removed from v.818  
changed lines
  Added in v.819

  ViewVC Help
Powered by ViewVC 1.1.5