summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authortc@google.com <tc@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-26 23:18:31 +0000
committertc@google.com <tc@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-26 23:18:31 +0000
commitf431e5a068edfe205170401311c0bc2adb1f4e6c (patch)
tree1433a1f9959720c264568da13797fa0edabd6475 /tools
parent37f881f80d889d817d5ded8d5393faa268eb5193 (diff)
downloadchromium_src-f431e5a068edfe205170401311c0bc2adb1f4e6c.zip
chromium_src-f431e5a068edfe205170401311c0bc2adb1f4e6c.tar.gz
chromium_src-f431e5a068edfe205170401311c0bc2adb1f4e6c.tar.bz2
Fix a bug where the flattened HTML file was not getting
included in data pack files. Review URL: http://codereview.chromium.org/28222 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10525 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools')
-rw-r--r--tools/grit/grit/node/include.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/grit/grit/node/include.py b/tools/grit/grit/node/include.py
index 032674b..e9ea31c 100644
--- a/tools/grit/grit/node/include.py
+++ b/tools/grit/grit/node/include.py
@@ -57,10 +57,9 @@ class IncludeNode(base.Node):
id_map = rc_header.Item.tids_
id = id_map[self.GetTextualIds()[0]]
filename = self.FilenameToOpen()
- if not os.path.exists(filename):
- # Try to open the file relative to the output dir if it's not relative to
- # the grd file.
- filename = os.path.join(output_dir, self.attrs['file'])
+ if self.attrs['flattenhtml'] == 'true':
+ # If the file was flattened, the flattened file is in the output dir.
+ filename = os.path.join(output_dir, os.path.split(filename)[1])
file = open(filename, 'rb')
data = file.read()