Change in libosmocore[master]: utils.h: add OSMO_NAME_C_IMPL() macro

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

neels gerrit-no-reply at lists.osmocom.org
Wed Nov 13 15:49:46 UTC 2019


neels has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/15957 )

Change subject: utils.h: add OSMO_NAME_C_IMPL() macro
......................................................................


Patch Set 7:

(1 comment)

https://gerrit.osmocom.org/c/libosmocore/+/15957/7/include/osmocom/core/utils.h 
File include/osmocom/core/utils.h:

https://gerrit.osmocom.org/c/libosmocore/+/15957/7/include/osmocom/core/utils.h@313 
PS7, Line 313: 		_str = (char*)talloc_named_const(CTX, _len, __func__); \
> because pseudotalloc doesn't know the size of the allocated buffer.
hmm, now that I think of it, realloc() would work.
But this is much simpler, particularly because we don't need to preserve the data in the buffer.
A realloc would require the OS to keep the data intact, so free and new alloc is actually my favorite now anyway.



-- 
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/15957
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ida5ba8d9640ea641aafef0236800f6d489d3d322
Gerrit-Change-Number: 15957
Gerrit-PatchSet: 7
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: osmith <osmith at sysmocom.de>
Gerrit-CC: pespin <pespin at sysmocom.de>
Gerrit-Comment-Date: Wed, 13 Nov 2019 15:49:46 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin at sysmocom.de>
Comment-In-Reply-To: neels <nhofmeyr at sysmocom.de>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191113/1770a056/attachment.htm>


More information about the gerrit-log mailing list