pike.git / lib / modules / ADT.pmod / module.pmod

version» Context lines:

pike.git/lib/modules/ADT.pmod/module.pmod:1:   #pike __REAL_VERSION__ + #pragma strict_types   inherit _ADT;      //! String buffer with the possibility to read and write data   //! as they would be formatted in structs.   class struct {       string buffer;    int index;       //! Create a new buffer, optionally initialized with the
pike.git/lib/modules/ADT.pmod/module.pmod:95:    //! the size of the array.    void put_var_uint_array(array(int) data, int item_size, int len)    {    put_uint(sizeof(data), len);    put_fix_uint_array(data, item_size);    }       //! Reads an unsigned integer from the buffer.    int(0..) get_uint(int len)    { -  mixed i; +  int(0..) i;    if ( (sizeof(buffer) - index) < len)    error("No data.\n");    sscanf(buffer, "%*" + (string) index +"s%" + (string) len + "c", i);    index += len;    return i;    }       //! Reads a fixed sized string of length @[len] from the buffer.    string get_fix_string(int len)    {