Project

General

Profile

« Previous | Next » 

Revision 39f1d449

Added by Marc Dequènes over 13 years ago

  • ID 39f1d4491e9af4d64521a2bfa062ef400d7abbf9

[fix] MapMaker/DNS: better check if zone has signed zone file before certain operations

View differences:

lib/cyborghood-mapmaker/dns/base.rb
end
def signed_content
read_zone(@filename_signed) unless @filename_signed.nil?
read_zone(@filename_signed) if has_signed_zone_file?
end
def content=(c)
......
end
def parsed_signed_content
return if @filename_signed.nil?
return unless has_signed_zone_file?
parsed_content = ZoneContent.new(@name)
parsed_content.import_from_file(@filename_signed)
......
end
def info
{
hszf = self.has_signed_zone_file?
data = {
:is_master => self.master?,
:has_signed_zone_file => self.has_signed_zone_file?,
:serial_in_zone_file => self.parsed_content.serial,
:serial_in_signed_zone_file => self.parsed_signed_content.serial
:has_signed_zone_file => hszf,
:serial_in_zone_file => self.parsed_content.serial
}
if hszf
data.merge!({
:serial_in_signed_zone_file => self.parsed_signed_content.serial
})
end
data
end
def __destroy

Also available in: Unified diff