From 05b4ec8683884ac9bd6ccde53e351ffe6562dc3d Mon Sep 17 00:00:00 2001 From: matz Date: Mon, 24 Jun 2002 07:59:02 +0000 Subject: * parse.y (yylex): __END__ should not be effective within string literals. * parse.y (here_document): should be aware of __END__ within here documents. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2592 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/pstore.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib/pstore.rb') diff --git a/lib/pstore.rb b/lib/pstore.rb index 4a3434b283..23b2d878a3 100644 --- a/lib/pstore.rb +++ b/lib/pstore.rb @@ -95,8 +95,7 @@ class PStore file.flock(read_only ? File::LOCK_SH : File::LOCK_EX) if read_only @table = Marshal::load(file) - elsif orig - content = file.read + elsif orig and (content = file.read) != nil @table = Marshal::load(content) size = content.size md5 = Digest::MD5.digest(content) -- cgit v1.2.3