Lines Matching refs:len
106 unsigned int len = *p; in zipmapDecodeLength() local
108 if (len < ZIPMAP_BIGLEN) return len; in zipmapDecodeLength()
109 memcpy(&len,p+1,sizeof(unsigned int)); in zipmapDecodeLength()
110 memrev32ifbe(&len); in zipmapDecodeLength()
111 return len; in zipmapDecodeLength()
116 static unsigned int zipmapEncodeLength(unsigned char *p, unsigned int len) { in zipmapEncodeLength() argument
118 return ZIPMAP_LEN_BYTES(len); in zipmapEncodeLength()
120 if (len < ZIPMAP_BIGLEN) { in zipmapEncodeLength()
121 p[0] = len; in zipmapEncodeLength()
125 memcpy(p+1,&len,sizeof(len)); in zipmapEncodeLength()
127 return 1+sizeof(len); in zipmapEncodeLength()
202 static inline unsigned char *zipmapResize(unsigned char *zm, unsigned int len) { in zipmapResize() argument
203 zm = zrealloc(zm, len); in zipmapResize()
204 zm[len-1] = ZIPMAP_END; in zipmapResize()
351 unsigned int len = 0; in zipmapLen() local
353 len = zm[0]; in zipmapLen()
356 while((p = zipmapNext(p,NULL,NULL,NULL,NULL)) != NULL) len++; in zipmapLen()
359 if (len < ZIPMAP_BIGLEN) zm[0] = len; in zipmapLen()
361 return len; in zipmapLen()