Age | Commit message (Collapse) | Author | Files | Lines |
|
Yes, the rename of structure members is a bit hacky.
Yes, catering to Windows since "GLib's v*printf routines are
surprisingly slow on Windows".
But it does pass checkAPIs.pl
Change-Id: I5b1552472c83aa2e159f17b5b7eb70b37d03eff9
Reviewed-on: https://code.wireshark.org/review/15404
Reviewed-by: Michael Mann <mmann78@netscape.net>
|
|
Fix the clang warning
epan/wmem/wmem_allocator_simple.c:49:27: error: equality comparison with extraneous parentheses [-Werror,-Wparentheses-equality]
if ((allocator->count == allocator->size)) {
~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
We might want to add -Wno-parentheses-equality to the compiler flag
list but I'm not sure if doing so would hide valid problems.
Change-Id: Id59b55af1411f13309fbec77870f869e04a6f49f
Reviewed-on: https://code.wireshark.org/review/1717
Reviewed-by: Gerald Combs <gerald@wireshark.org>
|
|
Instead of maintaining a hash table, just alloc a really big array of pointers.
This is theoretically bad since it means frees and reallocs become O(n), but in
practice it makes the capture from bug 10098 run about 20% faster under
valgrind. This makes sense, since the workload is heavily dominated by
allocations, and most frees/reallocs are recently allocated (so they will be
found quickly at the beginning of the scan).
Bug:10098
Change-Id: I7097ad0653d3fb5f4f723cc84046cbc4450e3494
Reviewed-on: https://code.wireshark.org/review/1602
Reviewed-by: Anders Broman <a.broman58@gmail.com>
|
|
(Using sed : sed -i '/^ \* \$Id\$/,+1 d')
Fix manually some typo (in export_object_dicom.c and crc16-plain.c)
Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8
Reviewed-on: https://code.wireshark.org/review/497
Reviewed-by: Anders Broman <a.broman58@gmail.com>
|
|
svn path=/trunk/; revision=54280
|
|
a NULL allocator. This gives us a single, central place to handle out-of-memory
errors (by, for example, throwing an exception) for basically all of epan.
The only remaining glib memory that is directly allocated is for the hash tables
used by the simple and strict allocators.
svn path=/trunk/; revision=51627
|
|
header later causes it to be redefined - as happens on my Solaris 11
virtual machine - we get a redefinition warning, which gets treated as
an error.
svn path=/trunk/; revision=51344
|
|
actual wmem_allocator_t structure. This simplifies the internal API and
deduplicates a few alloc/free calls in the individual allocator implementations.
I'd originally made the allocators responsible for this on purpose with the
idea that they'd be able to optimize something clever based on the type of
allocator, but that's clearly more work and complexity than it's worth given
the small number of allocators we create/destroy.
svn path=/trunk/; revision=49512
|
|
svn path=/trunk/; revision=48435
|
|
svn path=/trunk/; revision=48228
|
|
simple allocator. Thanks to Bill Meier for suggesting this.
svn path=/trunk/; revision=47815
|
|
alloc/free/realloc across all of wmem.
svn path=/trunk/; revision=47548
|
|
and document the fact that allocator authors don't have to care.
svn path=/trunk/; revision=47220
|
|
malloc/realloc/free.
svn path=/trunk/; revision=47215
|
|
svn path=/trunk/; revision=47172
|
|
valid non-error return from realloc if the new requested size is 0.
svn path=/trunk/; revision=47171
|
|
a GSList. This permits it to implement the new realloc and free functions. Also
fill in an empty gc function, since there isn't much it can do as far as
garbage-collection goes.
svn path=/trunk/; revision=47169
|
|
by any particular allocator) and better document the entire structure.
svn path=/trunk/; revision=47163
|
|
uses glib and 'simple' describes the intention far better.
svn path=/trunk/; revision=46603
|