From c57557c0d8d65c7343bca9029dc41ce130e6fc64 Mon Sep 17 00:00:00 2001 From: Mohamed Larabi Date: Tue, 26 Nov 2013 15:46:58 +0100 Subject: [PATCH] minor: fix save_rspec_to_file in sfi.py --- sfa/client/sfi.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sfa/client/sfi.py b/sfa/client/sfi.py index a51dc769..2f47839d 100644 --- a/sfa/client/sfi.py +++ b/sfa/client/sfi.py @@ -138,7 +138,7 @@ def save_rspec_to_file(rspec, filename): if not filename.endswith(".rspec"): filename = filename + ".rspec" f = open(filename, 'w') - f.write(rspec) + f.write("%s"%rspec) f.close() return @@ -1095,7 +1095,7 @@ use this if you mean an authority instead""") if self.options.raw: save_raw_to_file(result, self.options.raw, self.options.rawformat, self.options.rawbanner) if options.file is not None: - save_rspec_to_file(value, options.file) + save_rspec_to_file(value['geni_rspec'], options.file) if (self.options.raw is None) and (options.file is None): display_rspec(value, options.format) @@ -1136,7 +1136,7 @@ use this if you mean an authority instead""") if self.options.raw: save_raw_to_file(result, self.options.raw, self.options.rawformat, self.options.rawbanner) if options.file is not None: - save_rspec_to_file(value, options.file) + save_rspec_to_file(value['geni_rspec'], options.file) if (self.options.raw is None) and (options.file is None): display_rspec(value, options.format) @@ -1221,7 +1221,7 @@ use this if you mean an authority instead""") if self.options.raw: save_raw_to_file(result, self.options.raw, self.options.rawformat, self.options.rawbanner) if options.file is not None: - save_rspec_to_file (value, options.file) + save_rspec_to_file (value['geni_rspec'], options.file) if (self.options.raw is None) and (options.file is None): print value return value @@ -1281,7 +1281,7 @@ use this if you mean an authority instead""") if self.options.raw: save_raw_to_file(result, self.options.raw, self.options.rawformat, self.options.rawbanner) if options.file is not None: - save_rspec_to_file (value, options.file) + save_rspec_to_file (value['geni_rspec'], options.file) if (self.options.raw is None) and (options.file is None): print value return value -- 2.43.0