json: Add stpcpy replacement.
* src/gpgme-json.c [!HAVE_STPCPY](_my_stpcpy): New. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
67b4dafb6d
commit
8e34a14fe6
@ -114,6 +114,19 @@ static struct
|
|||||||
|
|
||||||
#define spacep(p) (*(p) == ' ' || *(p) == '\t')
|
#define spacep(p) (*(p) == ' ' || *(p) == '\t')
|
||||||
|
|
||||||
|
#ifndef HAVE_STPCPY
|
||||||
|
static GPGRT_INLINE char *
|
||||||
|
_my_stpcpy (char *a, const char *b)
|
||||||
|
{
|
||||||
|
while (*b)
|
||||||
|
*a++ = *b++;
|
||||||
|
*a = 0;
|
||||||
|
return a;
|
||||||
|
}
|
||||||
|
#define stpcpy(a,b) _my_stpcpy ((a), (b))
|
||||||
|
#endif /*!HAVE_STPCPY*/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
xoutofcore (const char *type)
|
xoutofcore (const char *type)
|
||||||
|
Loading…
Reference in New Issue
Block a user