cvs commit: modperl/src/modules/perl mod_perl.c perl_config.c
dougm 00/05/12 18:10:54 Modified:.Changes src/modules/perl mod_perl.c perl_config.c Log: add PerlAddVar directive, like PerlSetVar, but uses ap_table_add instead of ap_table_set Revision ChangesPath 1.482 +3 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.481 retrieving revision 1.482 diff -u -r1.481 -r1.482 --- Changes 2000/05/12 22:48:06 1.481 +++ Changes 2000/05/13 01:10:52 1.482 @@ -10,6 +10,9 @@ =item 1.23_01-dev +add PerlAddVar directive, like PerlSetVar, but uses ap_table_add +instead of ap_table_set + Makefile.PL warns about 5.6.0+uselargefiles if USE_APXS Apache::Table->unset can now be called with an array reference 1.117 +3 -0 modperl/src/modules/perl/mod_perl.c Index: mod_perl.c === RCS file: /home/cvs/modperl/src/modules/perl/mod_perl.c,v retrieving revision 1.116 retrieving revision 1.117 diff -u -r1.116 -r1.117 --- mod_perl.c2000/04/13 06:07:33 1.116 +++ mod_perl.c2000/05/13 01:10:53 1.117 @@ -126,6 +126,9 @@ { "PerlSetVar", (crft) perl_cmd_var, NULL, OR_ALL, TAKE2, "Perl config var and value" }, +{ "PerlAddVar", (crft) perl_cmd_var, + (void*)1, + OR_ALL, TAKE2, "Perl config var and value" }, { "PerlSetEnv", (crft) perl_cmd_setenv, NULL, OR_ALL, TAKE2, "Perl %ENV key and value" }, 1.97 +12 -2 modperl/src/modules/perl/perl_config.c Index: perl_config.c === RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v retrieving revision 1.96 retrieving revision 1.97 diff -u -r1.96 -r1.97 --- perl_config.c 2000/05/13 00:57:21 1.96 +++ perl_config.c 2000/05/13 01:10:53 1.97 @@ -729,11 +729,21 @@ MP_TRACE_d(fprintf(stderr, "perl_cmd_var: '%s' = '%s'\n", key, val)); if (cmd->path) { perl_dir_config *rec = (perl_dir_config *) config; -table_set(rec->vars, key, val); +if (cmd->info) { +table_add(rec->vars, key, val); +} +else { +table_set(rec->vars, key, val); +} } else { dPSRV(cmd->server); -table_set(cls->vars, key, val); +if (cmd->info) { +table_add(cls->vars, key, val); +} +else { +table_set(cls->vars, key, val); +} } return NULL; }
cvs commit: modperl ToDo
dougm 00/05/12 18:08:30 Modified:.ToDo Log: done Revision ChangesPath 1.243 +0 -2 modperl/ToDo Index: ToDo === RCS file: /home/cvs/modperl/ToDo,v retrieving revision 1.242 retrieving revision 1.243 diff -u -r1.242 -r1.243 --- ToDo 2000/05/12 07:10:56 1.242 +++ ToDo 2000/05/13 01:08:29 1.243 @@ -8,8 +8,6 @@ - do something about FreshRestart+dso ? (vivek) -- pass $Config{ccflags} to Apache's Makefile? (e.g. for -D_FILE_OFFSET_BITS) - - PERL_STATIC_EXTS doesnt work with USE_APACI=1 - solaris Perl Configure adds a space before -R in ccdlflags, see
cvs commit: modperl/src/modules/perl perl_config.c
dougm 00/05/12 17:57:22 Modified:src/modules/perl perl_config.c Log: HvKEYS fix was not the fix Revision ChangesPath 1.96 +2 -2 modperl/src/modules/perl/perl_config.c Index: perl_config.c === RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v retrieving revision 1.95 retrieving revision 1.96 diff -u -r1.95 -r1.96 --- perl_config.c 2000/05/04 04:52:34 1.95 +++ perl_config.c 2000/05/13 00:57:21 1.96 @@ -1178,7 +1178,7 @@ #define USE_ICASE 0 #endif -#define SECTION_NAME(n) (cmd->info ? (char *)cmd->info : n) +#define SECTION_NAME(n) n #define TRACE_SECTION(n,v) \ MP_TRACE_s(fprintf(stderr, "perl_section: <%s %s>\n", n, v)) @@ -1748,7 +1748,7 @@ } } - if((hv = GvHV((GV*)val)) && HvKEYS(hv)) { + if((hv = GvHV((GV*)val))) { perl_handle_command_hv(hv, key, parms, config); } else if((av = GvAV((GV*)val))) {
cvs commit: modperl Changes Makefile.PL
dougm 00/05/12 15:48:09 Modified:.Changes Makefile.PL Log: Makefile.PL warns about 5.6.0+uselargefiles if USE_APXS Revision ChangesPath 1.481 +2 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.480 retrieving revision 1.481 diff -u -r1.480 -r1.481 --- Changes 2000/05/12 22:45:30 1.480 +++ Changes 2000/05/12 22:48:06 1.481 @@ -10,6 +10,8 @@ =item 1.23_01-dev +Makefile.PL warns about 5.6.0+uselargefiles if USE_APXS + Apache::Table->unset can now be called with an array reference Apache::PerlRun::flush_namespace fixes, so aliased (imported) 1.161 +22 -5 modperl/Makefile.PL Index: Makefile.PL === RCS file: /home/cvs/modperl/Makefile.PL,v retrieving revision 1.160 retrieving revision 1.161 diff -u -r1.160 -r1.161 --- Makefile.PL 2000/04/27 22:45:30 1.160 +++ Makefile.PL 2000/05/12 22:48:07 1.161 @@ -1,4 +1,5 @@ -#! /usr/local/bin/perl +#!perl + BEGIN { $Is_Win32 = ($^O eq "MSWin32"); $Is_Cygwin = ($^O =~ m/cygwin/g); @@ -361,10 +362,8 @@ exit; } } - -system_sanity_check(); -if($USE_APXS) { +if ($USE_APXS) { if(-e $USE_APXS and !(-d _)) { $WITH_APXS = $USE_APXS; } @@ -382,7 +381,10 @@ print "\n"; ++$NO_HTTPD; } -elsif($USE_APACI) { + +system_sanity_check(); + +if ($USE_APACI) { print "Will configure via APACI"; gen_script("apaci/load_modules.pl"); if($USE_DSO) { @@ -2041,6 +2043,7 @@ gdbm_check(); malloc_check(); +uselargefiles_check(); dynaloader_check(); } @@ -2071,6 +2074,20 @@ EOF } } +} + +sub uselargefiles_check { +return unless $] >= 5.006 and $Config{uselargefiles} and $USE_APXS; +local $Apache::src::APXS = $WITH_APXS; +my $cflags = Apache::src->new->apxs('-q' => 'CFLAGS') || ''; +return if $cflags =~ /LARGEFILE/; + +phat_warn(<
cvs commit: modperl/src/modules/perl Table.xs
dougm 00/05/12 15:45:32 Modified:.Changes src/modules/perl Table.xs Log: Apache::Table->unset can now be called with an array reference Revision ChangesPath 1.480 +2 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.479 retrieving revision 1.480 diff -u -r1.479 -r1.480 --- Changes 2000/05/12 07:10:56 1.479 +++ Changes 2000/05/12 22:45:30 1.480 @@ -10,6 +10,8 @@ =item 1.23_01-dev +Apache::Table->unset can now be called with an array reference + Apache::PerlRun::flush_namespace fixes, so aliased (imported) code/hash/array/scalar are undefined without undef-ing the pointed-to data and without using B.pm, thanks to Richard Chen for the suggestion 1.9 +13 -5 modperl/src/modules/perl/Table.xs Index: Table.xs === RCS file: /home/cvs/modperl/src/modules/perl/Table.xs,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- Table.xs 1999/06/07 21:01:23 1.8 +++ Table.xs 2000/05/12 22:45:32 1.9 @@ -58,6 +58,11 @@ } +static void table_delete(table *tab, const char *key, const char *val) +{ +table_unset(tab, val); +} + static Apache__Table ApacheTable_new(table *utable) { Apache__Table RETVAL = (Apache__Table)safemalloc(sizeof(TiedTable)); @@ -148,9 +153,9 @@ RETVAL const char* -DELETE(self, key) +DELETE(self, sv) Apache::Table self -const char *key +SV *sv ALIAS: unset = 1 @@ -162,9 +167,12 @@ ix = ix; if(!self->utable) XSRETURN_UNDEF; RETVAL = NULL; -if(gimme != G_VOID) -RETVAL = table_get(self->utable, key); -table_unset(self->utable, key); +if((ix == 0) && (gimme != G_VOID)) { +STRLEN n_a; +RETVAL = table_get(self->utable, SvPV(sv,n_a)); +} + +table_modify(self, NULL, sv, (TABFUNC)table_delete); if(!RETVAL) XSRETURN_UNDEF; OUTPUT:
cvs commit: modperl-site/guide index_long.html CHANGES advocacy.html browserbugs.html config.html control.html correct_headers.html databases.html dbm.html debug.html download.html frequent.html hardware.html help.html index.html install.html intro.html mod_perl_guide.pdf.gz modules.html multiuser.html obvious.html performance.html perl.html porting.html scenario.html security.html snippets.html start.html strategy.html style.css troubleshooting.html
sbekman 00/05/12 15:43:02 Modified:guideCHANGES advocacy.html browserbugs.html config.html control.html correct_headers.html databases.html dbm.html debug.html download.html frequent.html hardware.html help.html index.html install.html intro.html mod_perl_guide.pdf.gz modules.html multiuser.html obvious.html performance.html perl.html porting.html scenario.html security.html snippets.html start.html strategy.html style.css troubleshooting.html Added: guideindex_long.html Log: * guide's layout changed: Now there are two index files -- the default index.html shows only the names of the chapters in TOC, the new index_long.html shows the full TOC as before. * guide's layout changed: Changed to simple black_on_white no fancy frames and colors anymore * guide: Changed the order of the the chapters towards logical sequentiality. * snippets: new: "Sending Cookies in REDIRECT Response" (Doug) * help: new: added the digest list info (Ask Bjoern Hansen) * performance: new: "Limiting the Number of Processes Serving the Same Resource" * troubleshooting: updated: "RegistryLoader: Translation of uri [...] to filename failed" * porting: update: "using format() and write()" -- using sprintf (Matt Sergeant) * perl: new: "Variables Globally, Lexically Scoped And Fully Qualified" (Ged W. Haywood) * build suite: documenting the build script so others could reuse this code in their documentation generation chores. * performance: a complete reorganizing of the content toward a better navigatibility. * strategy: removed "Multithreading or not Multithreading" -- has flaws and needs a rewrite * performance: update: "KeepAlive" -- works only if there is a Content-Length header (Andreas Koenig) * help: new: "get help with CVS" * troubleshooting: new: "Segfaults when using XML::Parser" (DeWitt Clinton) * performance: new: "Do Not Run Everything on One mod_perl Server" (Joshua Chamas, Shane [EMAIL PROTECTED], Gunther Birznieks) * minor corrections: scenario (Eric Jain), debug (Geoffrey Young). * install: new: "mod_perl and Raven SSL" (Doug) * scenario: new: "mod_proxy: Security Issues" (Eric Cholet) * performance: new: "Improving Perl Code Performance Hints" => "Concatination or List" (Doug) * debug: new: "hanging processes detection: Using the Perl Trace" * debug: new: "Hanging because of the OS Problem" (Greg Stark) * install: new: "About gdbm, db and ndbm libraries" (Les Mikesell) * performance: new: "Benchmarking Apache::Registry and Perl Content Handler" * performance: new: "Benchmarking CGI.pm and Apache::Request" * porting: new: "Transitioning from Apache::Registry to Apache handlers" * config: new: "Alias and Rewrite Conflicts" (Eric Cholet, Ask Bjoern Hansen, Vivek Vhera) * scenario: new: "Front-end Back-end Proxying with Virtual Hosts" (Vivek Vhera, Eric Cholet) * install: new: "APACHE_USER and APACHE_GROUP env" (Doug) * config: new: "Overriding Setting in "Sub-Location"" (Darren Chamberlain, Vivek Vhera) * review: Mark Summerfield has reviewed these chapters: porting, correct_headers, intro, multiuser, snippets and performance. * troubleshooting: new: "Processes Get Stuck on Graceful Restart" (Doug) * debug: updated: "Safe Resource Locking" added utils to trace the open files owner processes. (Doug, Eric Cholet) * databases: new: "Database Locking Risks" * performance: update: "Limiting the Resources Used by httpd Children", explanation of the soft and hard limits (Eric Cholet) * help: added subscription info for perl5-porters mailing list * perl: new: "Exception Handling for mod_perl" (Matt Sergeant) * review: Ged W. Haywood was very kind to review and correct the config, perl, dbm, snippets, advocacy, browserbugs, download, help, modules, troubleshooting, multiuser, obvious, correct_headers, status and hardware chapters. * modules: new: "Apache::RequestNotes" (Geoffrey Young) Revision ChangesPath 1.23 +114 -2modperl-site/guide/CHANGES Index: CHANGES === RCS file: /home/cvs/modperl-site/guide/CHANGES,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- CHANGES 2000/04/09 14:19:37 1.22 +++ CHANGES 2000/05/12 22:42:49 1.23 @@ -2,9 +2,121 @@ ### mod_perl Guide CHANGES file ### ### -04.10.2000 ver 1.22 -* updated the long due credits section +05.09.2000 ver 1.23 + +* guide's layout changed: Now th
Re: cvs commit: modperl-site index.html
> I'm sorry I lost my English somewhere, I type words but somehow they don't > get connected into sentences. Something is wrong with me :( happens to me too :) > Let's try again: > > The only concern is to have all the pages designed in the same way and not > only the the front page. Hmm, at least to arrange a link back to the > front page :) ok, i agree with that!
Re: cvs commit: modperl-site index.html
On Fri, 12 May 2000, Stas Bekman wrote: > The only concern is to have all the pages designed in > the same way and not only the the front page. Hmm, at > least to arrange a link back to the front page :) yah, i think he originally wanted to make sure folks were happy with the design before he did a bunch more work. i'll ping jim again to see where he's at with the work.
Re: cvs commit: modperl-site index.html
> > I didn't attempt to design, just to reorg the info. Sure, we've got +1 for > > jim's design. > > ok, your 'reorg' looks good then :) :) > > The only concern is that we have move than the front page and it'd be nice > > to have the other paged designed in the same fashion. Hmm, at least to > > arrange a link back to the front page :) > > sorry, i have trouble understanding, 'we have move than the front page' ? I'm sorry I lost my English somewhere, I type words but somehow they don't get connected into sentences. Something is wrong with me :( Let's try again: The only concern is to have all the pages designed in the same way and not only the the front page. Hmm, at least to arrange a link back to the front page :) __ Stas Bekman | JAm_pH--Just Another mod_perl Hacker http://stason.org/ | mod_perl Guide http://perl.apache.org/guide mailto:[EMAIL PROTECTED] | http://perl.orghttp://stason.org/TULARC/ http://singlesheaven.com| http://perlmonth.com http://sourcegarden.org --
Re: cvs commit: modperl-site index.html
On Fri, 12 May 2000, Stas Bekman wrote: > I didn't attempt to design, just to reorg the info. Sure, we've got +1 for > jim's design. ok, your 'reorg' looks good then :) > The only concern is that we have move than the front page and it'd be nice > to have the other paged designed in the same fashion. Hmm, at least to > arrange a link back to the front page :) sorry, i have trouble understanding, 'we have move than the front page' ?
Re: cvs commit: modperl-site index.html
On Thu, 11 May 2000, Doug MacEachern wrote: > On Sat, 6 May 2000, brian moseley wrote: > > > nah, it's still at > > http://www.vagabondage.com/~jim/modperl. it was just a > > preview, i was waiting for others to +1 it or whatever > > before i told him to finish it up. then i forgot about it. > > +1 on using jim's design! besides the fact that it's really slick, i > really like the idea of somebody designing the site who is not an actual > mod_perl user (or is he?), with his fresh perspective, the result should > lend itself well to new comers. > > stas, i like your redesign too, but if jim is willing and able to take on > site development, that frees you to focus on your other mod_perl projects > :) I didn't attempt to design, just to reorg the info. Sure, we've got +1 for jim's design. The only concern is that we have move than the front page and it'd be nice to have the other paged designed in the same fashion. Hmm, at least to arrange a link back to the front page :) __ Stas Bekman | JAm_pH--Just Another mod_perl Hacker http://stason.org/ | mod_perl Guide http://perl.apache.org/guide mailto:[EMAIL PROTECTED] | http://perl.orghttp://stason.org/TULARC/ http://singlesheaven.com| http://perlmonth.com http://sourcegarden.org --
cvs commit: modperl/t/net/perl dirty-script.cgi dirty-test.cgi
dougm 00/05/12 00:11:05 Modified:.Changes ToDo lib/Apache PerlRun.pm t/docs startup.pl t/modules perlrun.t t/net/perl dirty-script.cgi dirty-test.cgi Log: Apache::PerlRun::flush_namespace fixes, so aliased (imported) code/hash/array/scalar are undefined without undef-ing the pointed-to data and without using B.pm and: modules/perlrun was never properly run in the first place Revision ChangesPath 1.479 +4 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.478 retrieving revision 1.479 diff -u -r1.478 -r1.479 --- Changes 2000/05/05 08:10:33 1.478 +++ Changes 2000/05/12 07:10:56 1.479 @@ -10,6 +10,10 @@ =item 1.23_01-dev +Apache::PerlRun::flush_namespace fixes, so aliased (imported) +code/hash/array/scalar are undefined without undef-ing the pointed-to +data and without using B.pm, thanks to Richard Chen for the suggestion + document Apache::print's special behavior wrt references [Jeffrey W. Baker <[EMAIL PROTECTED]>] 1.242 +1 -4 modperl/ToDo Index: ToDo === RCS file: /home/cvs/modperl/ToDo,v retrieving revision 1.241 retrieving revision 1.242 diff -u -r1.241 -r1.242 --- ToDo 2000/04/21 17:04:56 1.241 +++ ToDo 2000/05/12 07:10:56 1.242 @@ -52,10 +52,7 @@ - coderef to $r->custom_response [Randal L. Schwartz <[EMAIL PROTECTED]>] -- PerlRun::flush_namespace needs to check if_owner for all types, not -just cvs. NOTE: i dont think this is possible, only CVs have a GV -pointer attached -dougm -[John M Vinopal <[EMAIL PROTECTED]>] +- Apache::PerlRun::flush_namespace should be re-written in c - should $r->content unset $r->headers_in('content-length') ? NOTE: im worried this could break apps who need to know content-length 1.28 +34 -20modperl/lib/Apache/PerlRun.pm Index: PerlRun.pm === RCS file: /home/cvs/modperl/lib/Apache/PerlRun.pm,v retrieving revision 1.27 retrieving revision 1.28 diff -u -r1.27 -r1.28 --- PerlRun.pm2000/04/05 06:19:34 1.27 +++ PerlRun.pm2000/05/12 07:10:57 1.28 @@ -312,36 +312,50 @@ return $rc; } +BEGIN { +if ($] < 5.006) { +$INC{'warnings.pm'} = __FILE__; +*warnings::unimport = sub {}; +} +} + sub flush_namespace { my($self, $package) = @_; $package ||= $self->namespace; -no strict; +no strict 'refs'; my $tab = \%{$package.'::'}; for (keys %$tab) { - if(*{ $tab->{$_} }{CODE}) { - undef_cv_if_owner($package, \&{ $tab->{$_} }); - } -if(*{ $tab->{$_} }{HASH}) { -undef %{ $tab->{$_} }; +my $fullname = join '::', $package, $_; +#code/hash/array/scalar might be imported +#make sure the gv does not point elsewhere +#before undefing each +if (%$fullname) { +*{$fullname} = {}; +undef %$fullname; } -if(*{ $tab->{$_} }{ARRAY}) { -undef @{ $tab->{$_} }; +if (@$fullname) { +*{$fullname} = []; +undef @$fullname; } -if(*{ $tab->{$_} }{SCALAR}) { - undef ${ $tab->{$_} }; +if ($$fullname) { +my $tmp; #argh, no such thing as an anonymous scalar +*{$fullname} = \$tmp; +undef $$fullname; } - } -} - -sub undef_cv_if_owner { -return unless $INC{'B.pm'}; -my($package, $cv) = @_; -my $obj= B::svref_2object($cv); -my $stash = $obj->GV->STASH->NAME; -return unless $package eq $stash; -undef &$cv; +if (defined &$fullname) { +no warnings; +local $^W = 0; +*{$fullname} = sub {}; + undef &$fullname; + } +if (*{$fullname}{IO}) { +if (fileno $fullname) { +close $fullname; +} +} +} } 1; 1.37 +5 -2 modperl/t/docs/startup.pl Index: startup.pl === RCS file: /home/cvs/modperl/t/docs/startup.pl,v retrieving revision 1.36 retrieving revision 1.37 diff -u -r1.36 -r1.37 --- startup.pl1999/04/07 03:34:35 1.36 +++ startup.pl2000/05/12 07:10:58 1.37 @@ -1,4 +1,4 @@ -#! /usr/local/bin/perl +#!perl unless (defined $ENV{MOD_PERL}) { die "\$ENV{MOD_PERL} not set!"; @@ -103,7 +103,10 @@ $ENV{GATEWAY_INTERFACE} =~ /^CGI-Perl/ or die "GAT