pike.git / src / modules / Image / encodings / xcf.c

version» Context lines:

pike.git/src/modules/Image/encodings/xcf.c:1:   #include "global.h" - RCSID("$Id: xcf.c,v 1.24 2000/10/10 20:50:54 grubba Exp $"); + RCSID("$Id: xcf.c,v 1.25 2000/10/17 20:07:20 per Exp $");      #include "image_machine.h"      #include "pike_macros.h"   #include "object.h"   #include "constants.h"   #include "module_support.h"   #include "interpret.h"   #include "object.h"   #include "svalue.h"
pike.git/src/modules/Image/encodings/xcf.c:320:    res = (char *)from->str;    from->str += len;    from->len -= len;    return res;   }      static struct buffer read_string( struct buffer *data )   {    struct buffer res = *data;    res.len = xcf_read_int( data ); -  res.base_len = res.len; -  res.base_offset = data->base_offset+(data->base_len-data->len); +  res.base_offset = (data->base_offset+(data->base_len-data->len));    res.str = (unsigned char *)read_data( data, res.len ); -  if(res.len > 0) res.len--; /* len includes ending \0 */ +  if(res.len > 0) res.len--; /* len includes ending \0 */ +  res.base_len = res.len;    if(!res.str)    error("String read failed\n");    return res;   }      static struct property read_property( struct buffer * data )   {    int i;    struct property res;    res.type = read_uint( data );