ixp_pstrings.3 (1321B)
1 .TH "IXP_PSTRINGS" 3 "2010 Jun" "libixp Manual" 2 3 .SH NAME 4 .P 5 ixp_pstrings 6 7 .SH SYNOPSIS 8 .nf 9 #include <ixp.h> 10 11 void ixp_pstrings(IxpMsg *msg, uint16_t *num, char *strings\fI[]\fR, uint max); 12 .fi 13 14 .SH DESCRIPTION 15 .P 16 Packs or unpacks an array of UTF\-8 encoded strings. The packed 17 representation consists of a 16\-bit element count followed by 18 an array of strings as packed by \fBixp_pstring(3)\fR. The unpacked 19 representation is an array of nul\-terminated character arrays. 20 21 .P 22 If ImsgR\->mode is MsgPack, I*numR strings in the array 23 pointed to by IstringsR are packed into the buffer at 24 ImsgR\->pos. If ImsgR\->mode is MsgUnpack, I*numR is loaded 25 with the number of strings unpacked, the array at 26 I*stringsR is loaded with pointers to the unpacked strings, 27 and I(*strings)\fI[0]\fRR must be freed by the user. In either 28 case, ImsgR\->pos is advanced by the number of bytes read or 29 written. If the action would advance ImsgR\->pos beyond 30 ImsgR\->end, ImsgR\->pos is still advanced, but no other 31 action is taken. If I*numR is greater than ImaxR, 32 ImsgR\->pos is set beyond ImsgR\->end and no other action is 33 taken. 34 35 .SH SEE ALSO 36 .P 37 IIxpMsgR, Iixp_pstringR, Iixp_pdataR 38 39 40 .\" man code generated by txt2tags 2.5 (http://txt2tags.sf.net) 41 .\" cmdline: txt2tags -o- ixp_pstrings.man3 42