summaryrefslogtreecommitdiff
path: root/scripts/const_structs.checkpatch
diff options
context:
space:
mode:
authorRasmus Villemoes <[email protected]>2026-04-21 09:54:35 +0200
committerTom Rini <[email protected]>2026-05-12 15:38:00 -0600
commitee8be5d4a1035de232b3497563fe9f6773775f96 (patch)
treec56925568ea459e1b7d151e0ad068f8b87e8573f /scripts/const_structs.checkpatch
parent8c664d2135723a110a60b792a8614c4864ad82a3 (diff)
lib/string.c: implement strdup() and strndup() in terms of memdup_nul()
With the addition of memdup_nul(), strdup() and strndup() can be implemented as one-liners. While not required by POSIX or C, do keep the behaviour of gracefully accepting a NULL source and simply return NULL. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Rasmus Villemoes <[email protected]>
Diffstat (limited to 'scripts/const_structs.checkpatch')
0 files changed, 0 insertions, 0 deletions