Return-Path: Mailing-List: contact modperl-help@apache.org; run by ezmlm Delivered-To: mailing list modperl@apache.org Received: (qmail 50764 invoked from network); 25 Mar 2000 17:21:22 -0000 Received: from unknown (HELO certsite.com) (208.13.34.61) by locus.apache.org with SMTP; 25 Mar 2000 17:21:22 -0000 Received: (qmail 12328 invoked from network); 25 Mar 2000 17:25:23 -0000 Received: from dsl-64-34-86-45.telocity.com (HELO certsite.com) (64.34.86.45) by 208.13.34.61 with SMTP; 25 Mar 2000 17:25:23 -0000 Sender: adi Message-ID: <38DCF72F.AA49975@certsite.com> Date: Sat, 25 Mar 2000 12:28:15 -0500 From: Adi X-Mailer: Mozilla 4.61 [en] (X11; I; Linux 2.2.12-20 i586) X-Accept-Language: en MIME-Version: 1.0 To: "Jeffrey W. Baker" CC: Simon Rosenthal , modperl@apache.org Subject: Re: Small Apache::Session improvement References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N "Jeffrey W. Baker" wrote: > > Actually the behavior is backward-compatible with existing Apache::Session > code. My code already ignores changes that do not occur in the top level > hash. This was both easy to right (sloth is a virtue), and fast at > runtime. The module could be rewritten to do a "deep" data structure > comparison, but that would be both hard and slow. > > -jwb I agree it should not do a deep comparison. That should be done outside Apache::Session if need be. My concern was whether you could make changes to the top-level hash and still get the same memory location for the new hash. say your session data was: $sesshash->{'foo'} => { 'bar' => 'baz' } at location: HASH(0x80c8554) you do a: $sesshash->{'foo'} = { 'bar' => 'baz', 'a' => 'b' }; can this new hash be allocated at the same memory location HASH(0x80c8554) ? If this can happen, it would lose data. Though I would guess it cannot occur, since perl's anonymous hash syntax {} creates a brand new hash, in unused memory, right? So I guess it's not much of a concern. Pardon the rambling.. -Adi