mirror of
https://github.com/alrayyes/st.git
synced 2024-11-26 21:06:23 +00:00
Make xrealloc and xstrdup style consistent.
This commit is contained in:
parent
df1810dd8f
commit
fa19f241a3
1 changed files with 2 additions and 4 deletions
6
st.c
6
st.c
|
@ -549,12 +549,10 @@ xrealloc(void *p, size_t len) {
|
||||||
|
|
||||||
char *
|
char *
|
||||||
xstrdup(char *s) {
|
xstrdup(char *s) {
|
||||||
char *p = strdup(s);
|
if((s = strdup(s)) == NULL)
|
||||||
|
|
||||||
if (!p)
|
|
||||||
die("Out of memory\n");
|
die("Out of memory\n");
|
||||||
|
|
||||||
return p;
|
return s;
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t
|
size_t
|
||||||
|
|
Loading…
Reference in a new issue