Lines Matching refs:data_len

27 	int data_len = end_data - data;  in asn1_encode_integer()  local
40 if (data_len < 3) in asn1_encode_integer()
44 data_len -= 2; in asn1_encode_integer()
70 data_len--; in asn1_encode_integer()
74 if (data_len == 0) in asn1_encode_integer()
78 data_len--; in asn1_encode_integer()
89 static int asn1_encode_oid_digit(unsigned char **_data, int *data_len, u32 oid) in asn1_encode_oid_digit() argument
95 if (*data_len < 1) in asn1_encode_oid_digit()
101 (*data_len)--; in asn1_encode_oid_digit()
108 while (start > 0 && *data_len > 0) { in asn1_encode_oid_digit()
116 (*data_len)--; in asn1_encode_oid_digit()
119 if (*data_len > 0) { in asn1_encode_oid_digit()
121 (*data_len)--; in asn1_encode_oid_digit()
144 int data_len = end_data - data; in asn1_encode_oid() local
159 if (data_len < 3) in asn1_encode_oid()
165 data_len -= 3; in asn1_encode_oid()
168 ret = asn1_encode_oid_digit(&d, &data_len, oid[i]); in asn1_encode_oid()
191 static int asn1_encode_length(unsigned char **data, int *data_len, int len) in asn1_encode_length() argument
193 if (*data_len < 1) in asn1_encode_length()
198 (*data_len)--; in asn1_encode_length()
204 (*data_len)--; in asn1_encode_length()
208 if (*data_len < 2) in asn1_encode_length()
214 *data_len -= 2; in asn1_encode_length()
218 if (*data_len < 3) in asn1_encode_length()
225 *data_len -= 3; in asn1_encode_length()
232 if (*data_len < 4) in asn1_encode_length()
238 *data_len -= 4; in asn1_encode_length()
273 int data_len = end_data - data; in asn1_encode_tag() local
293 data_len = 2; in asn1_encode_tag()
296 if (data_len < 2) in asn1_encode_tag()
300 data_len--; in asn1_encode_tag()
301 ret = asn1_encode_length(&data, &data_len, len); in asn1_encode_tag()
308 if (data_len < len) in asn1_encode_tag()
332 int data_len = end_data - data; in asn1_encode_octet_string() local
339 if (data_len < 2) in asn1_encode_octet_string()
343 data_len--; in asn1_encode_octet_string()
345 ret = asn1_encode_length(&data, &data_len, len); in asn1_encode_octet_string()
349 if (data_len < len) in asn1_encode_octet_string()
376 int data_len = end_data - data; in asn1_encode_sequence() local
393 data_len = 2; in asn1_encode_sequence()
396 if (data_len < 2) in asn1_encode_sequence()
400 data_len--; in asn1_encode_sequence()
402 ret = asn1_encode_length(&data, &data_len, len); in asn1_encode_sequence()
409 if (data_len < len) in asn1_encode_sequence()
429 int data_len = end_data - data; in asn1_encode_boolean() local
435 if (data_len < 3) in asn1_encode_boolean()
439 data_len--; in asn1_encode_boolean()
441 asn1_encode_length(&data, &data_len, 1); in asn1_encode_boolean()