httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pierre Leplay <Lep...@archimed.fr>
Subject Problem with pool allocation
Date Tue, 21 May 2002 13:48:22 GMT
I use a pool to alloc memory but It didn't work.The folowing line of code
explain my problem:

struct myStruct{
        char *var;
}

myStruct *myVar;

static apr_pool_t *archi_prox_pool = NULL;

void server_config(...){
        apr_pool_create(&archi_prox_pool, NULL);
        myVar=(char *)ap_palloc(archi_prox_pool,5*sizeof(char));
        myVar[0]=ap_pstrdup(archi_prox_pool,"servdev04");          

        //after ap_pstrdup myVar[0]="serv,รง{"
}

If anyone have an idea.

Best regards.

P.Leplay
					
        

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message