fix "No template found for item" warning and make it an error

Change-Id: I75985c3f8821b3506e46eaf572c54828db97c964
This commit is contained in:
Caolán McNamara
2012-07-26 10:05:50 +01:00
parent bb66a2c3ee
commit 947b3986d1
2 changed files with 5 additions and 1 deletions

View File

@@ -72,12 +72,16 @@ MIMELIST = \
master-document \ master-document \
oasis-text \ oasis-text \
oasis-text-template \ oasis-text-template \
oasis-text-flat-xml \
oasis-spreadsheet \ oasis-spreadsheet \
oasis-spreadsheet-template \ oasis-spreadsheet-template \
oasis-spreadsheet-flat-xml \
oasis-drawing \ oasis-drawing \
oasis-drawing-template \ oasis-drawing-template \
oasis-drawing-flat-xml \
oasis-presentation \ oasis-presentation \
oasis-presentation-template \ oasis-presentation-template \
oasis-presentation-flat-xml \
oasis-formula \ oasis-formula \
oasis-master-document \ oasis-master-document \
oasis-database \ oasis-database \

View File

@@ -119,7 +119,7 @@ foreach $template (keys %templates) {
# templates exist # templates exist
unless(open(TEMPLATE, $outfile)) { unless(open(TEMPLATE, $outfile)) {
print STDERR "Warning: No template found for item $_: $outfile: $!\n"; print STDERR "Warning: No template found for item $_: $outfile: $!\n";
next; exit -1;
} }
# open output file # open output file