summaryrefslogtreecommitdiffstats
path: root/common/mem.c
Commit message (Collapse)AuthorAgeFilesLines
* common: spice_memdup could accept NULLMarc-André Lureau2011-05-031-0/+4
| | | | (this patch is not to solve a crash fix, but to align with glib API)
* add #include <config.h> to all source filesChristophe Fergeau2011-05-031-0/+3
| | | | | | | | When using config.h, it must be the very first include in all source files since it contains #define that may change the compilation process (eg libc structure layout changes when it's used to enable large file support on 32 bit x86 archs). This commit adds it at the beginning of all .c and .cpp files
* common: add SpiceBuffer - based on qemu-vnc BufferMarc-André Lureau2011-02-281-0/+53
| | | | https://bugs.freedesktop.org/show_bug.cgi?id=34795
* Fix sign warnings from win32 compilerAlexander Larsson2010-07-081-2/+2
|
* Add spice_chunks_* helpersAlexander Larsson2010-07-071-0/+59
|
* Add spice_strnlenAlexander Larsson2010-06-171-0/+12
|
* Relicense everything from GPL to LGPL 2.1+Alexander Larsson2010-04-131-9/+9
|
* Add spice_strndupAlexander Larsson2010-03-241-0/+18
| | | | Also, make str(n)dup handle NULL correctly
* New memory allocators that exit on OOM and handle multiplication overflowAlexander Larsson2010-03-111-0/+150
Every place that does a regular malloc/calloc and aborts on failure should use spice_malloc/spice_mallo0 instead, which is leaner and cleaner. Allocations of dynamically sized arrays can use g_malloc_n or g_new etc which correctly handle multiplication overflow if some of the arguments are not trusted.