Skip to content

Commit

Permalink
Added a close method to recover the file handle.
Browse files Browse the repository at this point in the history
  • Loading branch information
cjheath committed Jun 3, 2009
1 parent 4f28cc6 commit 0b0dc63
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/geoip.rb
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,11 @@ def initialize(filename, flags = 0)
end
end

# Close the file handle for the GeoIP data file.
def close
@file.close
end

# Search the GeoIP database for the specified host, returning country info
#
# +hostname+ is a String holding the host's DNS name or numeric IP address.
Expand Down

0 comments on commit 0b0dc63

Please sign in to comment.