Overview
Comment: | Work around malloc(0) returning NULL. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
384257c4ccd990817ac28dad36597833 |
User & Date: | js on 2012-09-30 03:20:09 |
Other Links: | manifest | tags |
Context
2012-09-30
| ||
03:40 | Allow appending NULL to strings. check-in: 1adab684f6 user: js tags: trunk | |
03:20 | Work around malloc(0) returning NULL. check-in: 384257c4cc user: js tags: trunk | |
02:57 | Fix a bug in refpool. check-in: d7b09f1d63 user: js tags: trunk | |
Changes
Modified src/stream.c from [316847ca63] to [f662e79d40].
︙ | |||
116 117 118 119 120 121 122 | 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 | - - - - - + + + + + + + + | ret = cfw_create(cfw_string, NULL); if (ret == NULL) { free(ret_str); return NULL; } cfw_string_set_nocopy(ret, ret_str, ret_len); |
︙ | |||
200 201 202 203 204 205 206 | 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 | + - - - - - - + + + + + + + + + + - - - - - - + + + + + + + + + + + + | if (ret == NULL) { free(buf); free(ret_str); return NULL; } cfw_string_set_nocopy(ret, ret_str, ret_len); if (buf_len - i - 1 > 0) { |
︙ |