Skip to content

Commit

Permalink
* plugin/05referer.rb: ignore an invalid referer. (non-ASCII character)
Browse files Browse the repository at this point in the history
  • Loading branch information
machu committed Aug 24, 2010
1 parent f9e9d53 commit 823a583
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
2010-08-24 MATSUOKA Kohei <kohei@machu.jp>
* plugin/05referer.rb: ignore an invalid referer. (non-ASCII character)

2010-08-22 SHIBATA Hiroshi <shibata.hiroshi@gmail.com>
* misc/lib/compatible.rb: added String#lines, check convert to Enumerator in method_missing.
* misc/plugin/category.rb: fix bug. called String#map in make_anchor.
Expand Down
3 changes: 3 additions & 0 deletions plugin/05referer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,9 @@ def latest_day?( diary )
end

def referer_update( diary )
# ignore an invalid URL including a non-ASCII character
return if @cgi.referer && !@cgi.referer.match(/^[!-~]+$/)

@referer_volatile = RefererDiary::new( @conf.latest_limit )

case @mode
Expand Down

0 comments on commit 823a583

Please sign in to comment.