Skip to content

Commit

Permalink
Reset @mask_before_reopen in Syslog.mask=
Browse files Browse the repository at this point in the history
Without this, calling Syslog.open after Syslog.mask= will erroneously
reset the mask to the value stored in @mask_before_reopen
  • Loading branch information
Lewis Marshall committed Sep 18, 2012
1 parent c927f33 commit b9f7d0e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/syslog.rb.ffi
Expand Up @@ -128,6 +128,8 @@ module Syslog
raise RuntimeError, "must open syslog before setting log mask"
end

@mask_before_reopen = nil

@mask = Rubinius::Type.coerce_to mask, Fixnum, :to_int

Foreign.set_mask(@mask)
Expand Down

0 comments on commit b9f7d0e

Please sign in to comment.