strbuf: add xstrdup_toupper()

Create a copy of an existing string and make all characters upper case.
Similar xstrdup_tolower().

This function is used in a subsequent commit.

Signed-off-by: Lars Schneider <larsxschneider@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Lars Schneider
2018-02-15 16:27:06 +01:00
committed by Junio C Hamano
parent a8270b0980
commit 13ecb4638e
2 changed files with 13 additions and 0 deletions

View File

@ -607,6 +607,7 @@ __attribute__((format (printf,2,3)))
extern int fprintf_ln(FILE *fp, const char *fmt, ...);
char *xstrdup_tolower(const char *);
char *xstrdup_toupper(const char *);
/**
* Create a newly allocated string using printf format. You can do this easily