- Timestamp:
- May 4, 2017 5:22:44 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib-util/src/pjlib-util/base64.c
r4713 r5589 125 125 pj_uint8_t *out, int *out_len) 126 126 { 127 const char *buf = input->ptr;128 int len = (int)input->slen;127 const char *buf; 128 int len; 129 129 int i, j, k; 130 130 int c[4]; … … 132 132 PJ_ASSERT_RETURN(input && out && out_len, PJ_EINVAL); 133 133 134 while (buf[len-1] == '=' && len) 134 buf = input->ptr; 135 len = (int)input->slen; 136 while (len && buf[len-1] == '=') 135 137 --len; 136 138 … … 162 164 } 163 165 164 pj_assert(j < *out_len);166 pj_assert(j <= *out_len); 165 167 *out_len = j; 166 168
Note: See TracChangeset
for help on using the changeset viewer.