static mapcache_context* ngx_mapcache_context_clone(mapcache_context *ctx) {
   mapcache_context *nctx = (mapcache_context*)apr_pcalloc(ctx->pool,
         sizeof(mapcache_ngx_context));
   mapcache_context_copy(ctx,nctx);
   ((mapcache_ngx_context*)nctx)->r = ((mapcache_ngx_context*)ctx)->r;
   apr_pool_create(&nctx->pool,ctx->pool);
   return nctx;
}
Пример #2
0
static mapcache_context* fcgi_context_clone(mapcache_context *ctx)
{
  mapcache_context_fcgi *newctx = (mapcache_context_fcgi*)apr_pcalloc(ctx->pool,
                                  sizeof(mapcache_context_fcgi));
  mapcache_context *nctx = (mapcache_context*)newctx;
  mapcache_context_copy(ctx,nctx);
  apr_pool_create(&nctx->pool,ctx->pool);
  return nctx;
}
Пример #3
0
mapcache_context *mapcache_context_request_clone(mapcache_context *ctx)
{
  mapcache_context_apache_request *newctx = (mapcache_context_apache_request*)apr_pcalloc(ctx->pool,
      sizeof(mapcache_context_apache_request));
  mapcache_context *nctx = (mapcache_context*)newctx;
  mapcache_context_copy(ctx,nctx);
  //apr_pool_create(&nctx->pool,ctx->pool);
  apr_pool_create(&nctx->pool,NULL);
  apr_pool_cleanup_register(ctx->pool, nctx->pool,(void*)apr_pool_destroy, apr_pool_cleanup_null);
  newctx->request = ((mapcache_context_apache_request*)ctx)->request;
  return nctx;
}