diff options
author | Narayan Desai <desai@mcs.anl.gov> | 2006-05-15 20:07:32 +0000 |
---|---|---|
committer | Narayan Desai <desai@mcs.anl.gov> | 2006-05-15 20:07:32 +0000 |
commit | 1ef1dfeb7203242ffcc2ef4c27ed0e34f46337f7 (patch) | |
tree | 974192df32fdc56b8c4d701fd49962d937267c52 /src/lib/Server/Plugins/Cfg.py | |
parent | bef0233dacbdd6f63b08695e7622d40ab375ae04 (diff) | |
download | bcfg2-1ef1dfeb7203242ffcc2ef4c27ed0e34f46337f7.tar.gz bcfg2-1ef1dfeb7203242ffcc2ef4c27ed0e34f46337f7.tar.bz2 bcfg2-1ef1dfeb7203242ffcc2ef4c27ed0e34f46337f7.zip |
Add support for empty files
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1864 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Server/Plugins/Cfg.py')
-rw-r--r-- | src/lib/Server/Plugins/Cfg.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lib/Server/Plugins/Cfg.py b/src/lib/Server/Plugins/Cfg.py index f0f11b88e..402389663 100644 --- a/src/lib/Server/Plugins/Cfg.py +++ b/src/lib/Server/Plugins/Cfg.py @@ -200,6 +200,8 @@ class ConfigFileEntry(object): entry.attrib['paranoid'] = 'true' if entry.attrib['encoding'] == 'base64': entry.text = binascii.b2a_base64(filedata) + if filedata == '': + entry.set('empty', 'true') else: try: entry.text = filedata |