git.99rst.org
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
| inline |
side by side
(parent:
8c2462d
)
stash: declare ref_stash as an array
author
Denton Liu
<redacted>
Tue, 9 Feb 2021 07:28:53 +0000
(23:28 -0800)
committer
Junio C Hamano
<redacted>
Thu, 11 Feb 2021 21:34:58 +0000
(13:34 -0800)
Save sizeof(const char *) bytes by declaring ref_stash as an array
instead of having a redundant pointer to an array.
Signed-off-by: Denton Liu <redacted>
Signed-off-by: Junio C Hamano <redacted>
builtin/stash.c
patch
|
blob
|
history
diff --git
a/builtin/stash.c
b/builtin/stash.c
index 9bc85f91cd004024b5bba9bf9cb587101e9dedce..6f2b58f6ab2046aebd13a1a6486f1bd59662f7f9 100644
(file)
--- a/
builtin/stash.c
+++ b/
builtin/stash.c
@@
-87,7
+87,7
@@
static const char * const git_stash_save_usage[] = {
NULL
};
-static const char
*ref_stash
= "refs/stash";
+static const char
ref_stash[]
= "refs/stash";
static struct strbuf stash_index_path = STRBUF_INIT;
/*
git clone https://git.99rst.org/PROJECT