diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-02-02 13:36:55 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-02-02 13:36:55 -0800 |
commit | 6f1c08bdb75b37ad30103f0f12339780fdc004e2 (patch) | |
tree | 3a6909ffaaa512519c3f6f6e7a11f0956276bcd1 /contrib | |
parent | Merge branch 'js/unzip-in-usr-bin-workaround' (diff) | |
parent | use absolute_pathdup() (diff) | |
download | tgif-6f1c08bdb75b37ad30103f0f12339780fdc004e2.tar.xz |
Merge branch 'rs/absolute-pathdup'
Code cleanup.
* rs/absolute-pathdup:
use absolute_pathdup()
abspath: add absolute_pathdup()
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/coccinelle/xstrdup_or_null.cocci | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/contrib/coccinelle/xstrdup_or_null.cocci b/contrib/coccinelle/xstrdup_or_null.cocci index 3fceef132b..8e05d1ca4b 100644 --- a/contrib/coccinelle/xstrdup_or_null.cocci +++ b/contrib/coccinelle/xstrdup_or_null.cocci @@ -5,3 +5,9 @@ expression V; - if (E) - V = xstrdup(E); + V = xstrdup_or_null(E); + +@@ +expression E; +@@ +- xstrdup(absolute_path(E)) ++ absolute_pathdup(E) |