sizeof(char) is always 1, no need to be explicit - noice - small file browser (… | |
git clone git://git.codemadness.org/noice | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit e27af6f1dbc804e90a3b98f19afdf1055bab8dc9 | |
parent a7152012558006b0f0ffca633c8c90ff4ce9726d | |
Author: sin <[email protected]> | |
Date: Wed, 6 Jan 2016 15:24:35 +0000 | |
sizeof(char) is always 1, no need to be explicit | |
Diffstat: | |
M noice.c | 4 ++-- | |
1 file changed, 2 insertions(+), 2 deletions(-) | |
--- | |
diff --git a/noice.c b/noice.c | |
@@ -235,8 +235,8 @@ setfilter(regex_t *regex, char *filter) | |
r = regcomp(regex, filter, REG_NOSUB | REG_EXTENDED | REG_ICASE); | |
if (r != 0) { | |
- errbuf = xmalloc(COLS * sizeof(char)); | |
- regerror(r, regex, errbuf, COLS * sizeof(char)); | |
+ errbuf = xmalloc(COLS); | |
+ regerror(r, regex, errbuf, COLS); | |
printmsg(errbuf); | |
free(errbuf); | |
} |