pike.git / src / encode.c

version» Context lines:

pike.git/src/encode.c:18:   #include "error.h"   #include "operators.h"   #include "builtin_functions.h"   #include "module_support.h"   #include "fsort.h"   #include "threads.h"   #include "stuff.h"   #include "version.h"   #include "bignum.h"    - RCSID("$Id: encode.c,v 1.66 2000/08/15 16:15:43 grubba Exp $"); + RCSID("$Id: encode.c,v 1.67 2000/08/16 10:50:42 grubba Exp $");      /* #define ENCODE_DEBUG */      #ifdef ENCODE_DEBUG   #define EDB(X) X   #else   #define EDB(X)   #endif      /* The sp macro conflicts with Solaris 2.5.1's <sys/conf.h>. */
pike.git/src/encode.c:1588:       SET_ONERROR(err, free_decode_data, data);    decode_value2(data);    UNSET_ONERROR(err);    free_mapping(data->decoded);    return 1;   }      /* Compatibilidy decoder */    - static unsigned char extract_char(char **v, INT32 *l) + static unsigned char extract_char(char **v, ptrdiff_t *l)   {    if(!*l) error("Format error, not enough place for char.\n");    else (*l)--;    (*v)++;    return ((unsigned char *)(*v))[-1];   }    - static ptrdiff_t extract_int(char **v, INT32 *l) + static ptrdiff_t extract_int(char **v, ptrdiff_t *l)   {    INT32 j;    ptrdiff_t i;       j=extract_char(v,l);    if(j & 0x80) return (j & 0x7f);       if((j & ~8) > 4)    error("Format Error: Error in format string, invalid integer.\n");    i=0;    while(j & 7) { i=(i<<8) | extract_char(v,l); j--; }    if(j & 8) return -i;    return i;   }    - static void rec_restore_value(char **v, INT32 *l) + static void rec_restore_value(char **v, ptrdiff_t *l)   {    ptrdiff_t t, i;       i = extract_int(v,l);    t = extract_int(v,l);    switch(i)    {    case TAG_INT:    push_int(DO_NOT_WARN(t));    return;