COMP: Try to remove setenv warning
This commit is contained in:
parent
089d339721
commit
b71410117e
|
@ -37,6 +37,8 @@ void xmlrpc_authcookie_set ( xmlrpc_env *env,
|
||||||
const char *password ) {
|
const char *password ) {
|
||||||
char *unencoded;
|
char *unencoded;
|
||||||
xmlrpc_mem_block *token;
|
xmlrpc_mem_block *token;
|
||||||
|
static char env_buffer[1024];
|
||||||
|
const char* block;
|
||||||
|
|
||||||
/* Check asserts. */
|
/* Check asserts. */
|
||||||
XMLRPC_ASSERT_ENV_OK(env);
|
XMLRPC_ASSERT_ENV_OK(env);
|
||||||
|
@ -56,8 +58,9 @@ void xmlrpc_authcookie_set ( xmlrpc_env *env,
|
||||||
|
|
||||||
/* Set HTTP_COOKIE_AUTH to the character representation of the
|
/* Set HTTP_COOKIE_AUTH to the character representation of the
|
||||||
** encoded string. */
|
** encoded string. */
|
||||||
setenv("HTTP_COOKIE_AUTH", XMLRPC_TYPED_MEM_BLOCK_CONTENTS(char, token),
|
block = XMLRPC_TYPED_MEM_BLOCK_CONTENTS(char, token);
|
||||||
1);
|
sprintf(env_buffer, "HTTP_COOKIE_AUTH=%s", block);
|
||||||
|
putenv(env_buffer);
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
if (token) xmlrpc_mem_block_free(token);
|
if (token) xmlrpc_mem_block_free(token);
|
||||||
|
|
Loading…
Reference in New Issue