Return-Path: X-Original-To: apmail-perl-modperl-archive@www.apache.org Delivered-To: apmail-perl-modperl-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D65D69E2A for ; Wed, 12 Nov 2014 16:46:47 +0000 (UTC) Received: (qmail 78975 invoked by uid 500); 12 Nov 2014 16:46:47 -0000 Delivered-To: apmail-perl-modperl-archive@perl.apache.org Received: (qmail 78939 invoked by uid 500); 12 Nov 2014 16:46:47 -0000 Mailing-List: contact modperl-help@perl.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list modperl@perl.apache.org Received: (qmail 78929 invoked by uid 99); 12 Nov 2014 16:46:46 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Nov 2014 16:46:46 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of adam.prime@utoronto.ca designates 128.100.132.182 as permitted sender) Received: from [128.100.132.182] (HELO bureau82.ns.utoronto.ca) (128.100.132.182) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Nov 2014 16:46:42 +0000 Received: from [10.1.4.160] (h216-235-10-210.host.egate.net [216.235.10.210]) (authenticated bits=0) by bureau82.ns.utoronto.ca (8.13.8/8.13.8) with ESMTP id sACGjEv1006089 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Wed, 12 Nov 2014 11:45:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=utoronto.ca; s=beta; t=1415810717; bh=oq9oEbCIYYhybMowZGq77DubMgl/z5pZ8w/30ST2UMQ=; h=Message-ID:Date:From:MIME-Version:To:Subject:References: In-Reply-To:Content-Type:Content-Transfer-Encoding; b=zjkqiwUixf1cLtHj3T4irT3stwyJXRoG/bpVDLdKl+IzXrfEztq/zp26QsW93ZsWk ryovDFMuy+AEwiao7scTysLrpbNLC+NTq/Pt9HDSIGvmJLxlq9u/OcJANSF6MAjlyl GupXovxxe+aymqNbAIGchUB2DE/NuEfIC5+unx9w= Message-ID: <54638E99.6050306@utoronto.ca> Date: Wed, 12 Nov 2014 11:45:13 -0500 From: Adam Prime User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: Alexandr Evstigneev , modperl@perl.apache.org Subject: Re: mod_perl2: 304 (not modified) and custom headers References: In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Can we see the code you're running into this issue with? It sounds like confusion between $r->headers_out and $r->err_headers_out to me. Adam On 14-11-12 05:09 AM, Alexandr Evstigneev wrote: > 1. Problem Description: > > It seems, that if I set status to 304, all custom headers being ignored > and not sent to to the client. > I'm making cross-domain ajax script and it should pass > Access-Control-Allow-Origin even on 304 response. > Works fine if data been modified but 304 response has no my headers. > > 2. Used Components and their Configuration: > > *** mod_perl version 2.000008 > > *** using /usr/local/lib/perl5/site_perl/5.20/mach/Apache2/BuildConfig.pm > > *** Makefile.PL options: > MP_APR_CONFIG => /usr/local/bin/apr-1-config > MP_APR_LIB => aprext > MP_APXS => /usr/local/sbin/apxs > MP_COMPAT_1X => 1 > MP_GENERATE_XS => 1 > MP_LIBNAME => mod_perl > MP_USE_DSO => 1 > > > *** The httpd binary was not found > > > *** (apr|apu)-config linking info > > -L/usr/local/lib -laprutil-1 -ldb-5.3 -lgdbm -lexpat -liconv > -L/usr/lib -L/usr/local/lib -L/usr/local/lib/db5 > -L/usr/local/lib -lapr-1 -lcrypt -lpthread > > > > *** /usr/local/bin/perl -V > Summary of my perl5 (revision 5 version 20 subversion 1) configuration: > > Platform: > osname=freebsd, osvers=9.3-release-p4, > archname=amd64-freebsd-thread-multi > uname='freebsd storage.cobweb-software.com > 9.3-release-p4 freebsd > 9.3-release-p4 #0 r273928: sat nov 1 17:16:18 msk 2014 > root@storage.cobweb-software.com:usrobjusrsrcsysgeneric amd64 ' > config_args='-sde -Dprefix=/usr/local > -Darchlib=/usr/local/lib/perl5/5.20/mach > -Dprivlib=/usr/local/lib/perl5/5.20 > -Dman3dir=/usr/local/lib/perl5/5.20/perl/man/man3 > -Dman1dir=/usr/local/man/man1 > -Dsitearch=/usr/local/lib/perl5/site_perl/5.20/mach > -Dsitelib=/usr/local/lib/perl5/site_perl/5.20 -Dscriptdir=/usr/local/bin > -Dsiteman3dir=/usr/local/lib/perl5/5.20/man/man3 > -Dsiteman1dir=/usr/local/man/man1 -Ui_malloc -Ui_iconv > -Uinstallusrbinperl -Dcc=cc -Duseshrplib -Dinc_version_list=none > -Dccflags=-DAPPLLIB_EXP="/usr/local/lib/perl5/5.20/BSDPAN" -Doptimize=-g > -DDEBUGGING -Ui_gdbm -Dusemultiplicity=y -Duse64bitint -Dusethreads=y > -Dusemymalloc=n' > hint=recommended, useposix=true, d_sigaction=define > useithreads=define, usemultiplicity=define > use64bitint=define, use64bitall=define, uselongdouble=undef > usemymalloc=n, bincompat5005=undef > Compiler: > cc='cc', ccflags ='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.20/BSDPAN" > -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -DDEBUGGING -fno-strict-aliasing > -pipe -fstack-protector -I/usr/local/include', > optimize='-g', > cppflags='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.20/BSDPAN" > -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -DDEBUGGING -fno-strict-aliasing > -pipe -fstack-protector -I/usr/local/include' > ccversion='', gccversion='4.2.1 20070831 patched [FreeBSD]', > gccosandvers='' > intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678 > d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16 > ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', > lseeksize=8 > alignbytes=8, prototype=define > Linker and Libraries: > ld='cc', ldflags ='-pthread -Wl,-E -fstack-protector -L/usr/local/lib' > libpth=/usr/lib /usr/local/lib /usr/include/gcc/4.2 /usr/lib > libs=-lgdbm -lm -lcrypt -lutil > perllibs=-lm -lcrypt -lutil > libc=, so=so, useshrplib=true, libperl=libperl.so > gnulibc_version='' > Dynamic Linking: > dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' > -Wl,-R/usr/local/lib/perl5/5.20/mach/CORE' > cccdlflags='-DPIC -fPIC', lddlflags='-shared -L/usr/local/lib > -fstack-protector' > > > Characteristics of this binary (from libperl): > Compile-time options: DEBUGGING HAS_TIMES MULTIPLICITY PERLIO_LAYERS > PERL_DONT_CREATE_GVSV > PERL_HASH_FUNC_ONE_AT_A_TIME_HARD > PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP > PERL_NEW_COPY_ON_WRITE PERL_PRESERVE_IVUV > PERL_TRACK_MEMPOOL USE_64_BIT_ALL USE_64_BIT_INT > USE_ITHREADS USE_LARGE_FILES USE_LOCALE > USE_LOCALE_COLLATE USE_LOCALE_CTYPE > USE_LOCALE_NUMERIC USE_PERLIO USE_PERL_ATOF > USE_REENTRANT_API > Built under freebsd > Compiled at Nov 9 2014 08:27:44 > %ENV: > PERL5LIB="/raid/www/lib" > PERL_LWP_USE_HTTP_10="1" > @INC: > /raid/www/lib > /usr/local/lib/perl5/5.20/BSDPAN > /usr/local/lib/perl5/site_perl/5.20/mach > /usr/local/lib/perl5/site_perl/5.20 > /usr/local/lib/perl5/5.20/mach > /usr/local/lib/perl5/5.20 > . > > *** Packages of interest status: > > Apache2 : - > Apache2::Request : - > CGI : 3.65 > ExtUtils::MakeMaker: 6.98, 6.98 > LWP : 6.08 > mod_perl : - > mod_perl2 : 2.000008 > > > 3. This is the core dump trace: (if you get a core dump): > > [CORE TRACE COMES HERE] > > This report was generated by /usr/local/bin/mp2bug on Wed Nov 12 > 09:51:30 2014 GMT.