pike.git / src / encode.c

version» Context lines:

pike.git/src/encode.c:299:    tmp=data->counter;    data->counter.u.integer++;    push_int(num);    break;       case T_STRING:    tmp=data->counter;    data->counter.u.integer++;    if(data->ptr + num > data->len)    error("Failed to decode string. (string range error)\n"); -  push_string(make_shared_binary_string(data->data + data->ptr, num)); +  push_string(make_shared_binary_string((char *)(data->data + data->ptr), num));    data->ptr+=num;    break;       case T_FLOAT:    {    INT32 num2=num;       tmp=data->counter;    data->counter.u.integer++;   
pike.git/src/encode.c:415:    free_mapping(data->decoded);   }      static INT32 my_decode(struct pike_string *tmp)   {    ONERROR err;    struct decode_data d, *data;    data=&d;    data->counter.type=T_INT;    data->counter.u.integer=COUNTER_START; -  data->data=tmp->str; +  data->data=(unsigned char *)tmp->str;    data->len=tmp->len;    data->ptr=0;       if(data->len < 5) return 0;    if(GETC() != 182 ||    GETC() != 'k' ||    GETC() != 'e' ||    GETC() != '0')    return 0;