Unified · Split
| @@ -15,6 +15,9 @@ libavutil: 2015-08-28 · 14 unmodified lines | ||
| 15 | 15 | |
| 16 | 16 | API changes, most recent first: |
| 17 | 17 | |
| 18 | +2015-11-18 - lavu 55.7.100 - mem.h | |
| 19 | + Add av_fast_mallocz() | |
| 20 | + | |
| 18 | 21 | 2015-10-29 - lavc 57.12.100 / 57.8.0 - avcodec.h |
| 19 | 22 | xxxxxx - Deprecate av_free_packet(). Use av_packet_unref() as replacement, |
| 20 | 23 | it resets the packet in a more consistent way. |
| @@ -501,3 +501,7 @@ void av_fast_malloc(void *ptr, unsigned int *size, size_t min_size) · 500 unmodified lines | ||
| 501 | 501 | ff_fast_malloc(ptr, size, min_size, 0); |
| 502 | 502 | } |
| 503 | 503 | |
| 504 | +void av_fast_mallocz(void *ptr, unsigned int *size, size_t min_size) | |
| 505 | +{ | |
| 506 | + ff_fast_malloc(ptr, size, min_size, 1); | |
| 507 | +} | |
| @@ -384,6 +384,21 @@ void *av_fast_realloc(void *ptr, unsigned int *size, size_t min_size); · 383 unmodified lines | ||
| 384 | 384 | */ |
| 385 | 385 | void av_fast_malloc(void *ptr, unsigned int *size, size_t min_size); |
| 386 | 386 | |
| 387 | +/** | |
| 388 | + * Allocate a buffer, reusing the given one if large enough. | |
| 389 | + * | |
| 390 | + * All newly allocated space is initially cleared | |
| 391 | + * Contrary to av_fast_realloc the current buffer contents might not be | |
| 392 | + * preserved and on error the old buffer is freed, thus no special | |
| 393 | + * handling to avoid memleaks is necessary. | |
| 394 | + * | |
| 395 | + * @param ptr pointer to pointer to already allocated buffer, overwritten with pointer to new buffer | |
| 396 | + * @param size size of the buffer *ptr points to | |
| 397 | + * @param min_size minimum size of *ptr buffer after returning, *ptr will be NULL and | |
| 398 | + * *size 0 if an error occurred. | |
| 399 | + */ | |
| 400 | +void av_fast_mallocz(void *ptr, unsigned int *size, size_t min_size); | |
| 401 | + | |
| 387 | 402 | /** |
| 388 | 403 | * @} |
| 389 | 404 | */ |
| @@ -56,7 +56,7 @@ · 55 unmodified lines | ||
| 56 | 56 | */ |
| 57 | 57 | |
| 58 | 58 | #define LIBAVUTIL_VERSION_MAJOR 55 |
| 59 | −#define LIBAVUTIL_VERSION_MINOR 6 | |
| 59 | +#define LIBAVUTIL_VERSION_MINOR 7 | |
| 60 | 60 | #define LIBAVUTIL_VERSION_MICRO 100 |
| 61 | 61 | |
| 62 | 62 | #define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \ |