chiark / gitweb /
util: use a shared lookup function for string tables
authorBruno Bottazzini <bruno.bottazzini@intel.com>
Fri, 13 Feb 2015 20:40:50 +0000 (18:40 -0200)
committerDavid Herrmann <dh.herrmann@gmail.com>
Sat, 14 Feb 2015 13:32:27 +0000 (14:32 +0100)
Macro DEFINE_STRING_TABLE_LOOKUP expands to a new function for each
of the almost 120 tables throghout the code.
Move the its implementation to a function (guaranteed to never be inlined),
and make the macro expand to an inlined function that calls this function.
This saves a few kilobytes from the systemd binary

(David: - fix coding-style
        - use 'ssize_t' to fix 32bit to 64bit propagation
        - use streq_ptr())


No differences found