1
0
mirror of https://github.com/CumulusNetworks/ifupdown2.git synced 2024-05-06 15:54:50 +00:00

Call mako renderer before rendering backslashes ('\')

Ticket: CM-5104
Reviewed By:
Testing Done: Tested with interfaces file listed in the bug
This commit is contained in:
Roopa Prabhu
2015-02-18 12:28:50 -08:00
parent 496745cdc0
commit 5b65654f85

View File

@@ -344,6 +344,10 @@ class networkInterfaces():
return classes
def process_interfaces(self, filedata):
# process line continuations
filedata = ' '.join(d.strip() for d in filedata.split('\\'))
line_idx = 0
lines_consumed = 0
raw_config = filedata.split('\n')
@@ -369,8 +373,6 @@ class networkInterfaces():
def read_filedata(self, filedata):
self._currentfile_has_template = False
# process line continuations
filedata = ' '.join(d.strip() for d in filedata.split('\\'))
# run through template engine
try:
rendered_filedata = self._template_engine.render(filedata)