diff options
author | Neal H. Walfield <[email protected]> | 2015-03-12 12:03:50 +0000 |
---|---|---|
committer | Neal H. Walfield <[email protected]> | 2015-03-12 12:54:31 +0000 |
commit | e40636fefa7f9ded8216e3e55606ffc5c34cbce6 (patch) | |
tree | 24fa595ebea5ca130113baad1e96179bcf64bf71 /common/stringhelp.h | |
parent | agent: Improve error reporting from Pinentry. (diff) | |
download | gnupg-e40636fefa7f9ded8216e3e55606ffc5c34cbce6.tar.gz gnupg-e40636fefa7f9ded8216e3e55606ffc5c34cbce6.zip |
common: Add new helper function, strsplit.
* common/stringhelp.h (strsplit): New declaration.
* common/stringhelp.c (strsplit): New function.
* common/t-stringhelp.c (test_strsplit): New function.
(main): Call it here.
--
Diffstat (limited to 'common/stringhelp.h')
-rw-r--r-- | common/stringhelp.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/common/stringhelp.h b/common/stringhelp.h index ffef2d52f..864a6893b 100644 --- a/common/stringhelp.h +++ b/common/stringhelp.h @@ -1,6 +1,7 @@ /* stringhelp.h * Copyright (C) 1998, 1999, 2000, 2001, 2003, * 2006, 2007, 2009 Free Software Foundation, Inc. + * 2015 g10 Code GmbH * * This file is part of JNLIB, which is a subsystem of GnuPG. * @@ -142,9 +143,9 @@ char *strconcat (const char *s1, ...) GNUPG_GCC_A_SENTINEL(0); /* Ditto, but die on error. */ char *xstrconcat (const char *s1, ...) GNUPG_GCC_A_SENTINEL(0); +char **strsplit (char *string, char delim, char replacement, int *count); /*-- mapstrings.c --*/ const char *map_static_macro_string (const char *string); - #endif /*LIBJNLIB_STRINGHELP_H*/ |