mirror of
https://gitee.com/bianbu-linux/linux-6.6
synced 2025-04-24 14:07:52 -04:00
libstring_helpers.c:string_get_size(): return void
string_get_size() was documented to return an error, but in fact always returned 0. Since the output always fits in 9 bytes, just document that and let callers do what they do now: pass a small stack buffer and ignore the return value. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
84b9fbedf5
commit
d1214c65c0
2 changed files with 6 additions and 8 deletions
|
@ -10,8 +10,8 @@ enum string_size_units {
|
|||
STRING_UNITS_2, /* use binary powers of 2^10 */
|
||||
};
|
||||
|
||||
int string_get_size(u64 size, enum string_size_units units,
|
||||
char *buf, int len);
|
||||
void string_get_size(u64 size, enum string_size_units units,
|
||||
char *buf, int len);
|
||||
|
||||
#define UNESCAPE_SPACE 0x01
|
||||
#define UNESCAPE_OCTAL 0x02
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue