diff options
| author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-11-19 16:59:11 +0000 |
|---|---|---|
| committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-11-19 16:59:11 +0000 |
| commit | 12bec49093666b9350f566f50339144d5f92e9e5 (patch) | |
| tree | 2db9083082e24f1742da09ce7899a7427f965ae9 /lib/cgi/session | |
| parent | c57202b8b4a3e48855bd687dff294bf28376ef9a (diff) | |
| download | ruby-12bec49093666b9350f566f50339144d5f92e9e5.tar.gz ruby-12bec49093666b9350f566f50339144d5f92e9e5.tar.xz ruby-12bec49093666b9350f566f50339144d5f92e9e5.zip | |
* string.c (str_gsub): internal buffer should not be listed by
ObjectSpace.each_object() by String#gsub. [ruby-dev:24931]
* lib/cgi/session.rb (CGI::Session::FileStore::initialize): raise
exception if data corresponding to session specified from the
client does not exist.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@7326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/cgi/session')
| -rw-r--r-- | lib/cgi/session/pstore.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/cgi/session/pstore.rb b/lib/cgi/session/pstore.rb index e2727b5c5..40d2214c2 100644 --- a/lib/cgi/session/pstore.rb +++ b/lib/cgi/session/pstore.rb @@ -61,7 +61,10 @@ class CGI md5 = Digest::MD5.hexdigest(id)[0,16] path = dir+"/"+prefix+md5 path.untaint - unless File::exist? path + unless File::exist?(path) + unless session.new_session + raise RuntimeError, "uninitialized session" + end @hash = {} end @p = ::PStore.new(path) |
