summaryrefslogtreecommitdiff
path: root/src/libs
diff options
context:
space:
mode:
authorG. Branden Robinson <g.branden.robinson@gmail.com>2021-09-17 16:29:43 +1000
committerG. Branden Robinson <g.branden.robinson@gmail.com>2021-09-17 16:34:06 +1000
commitc5772157d1136372470f5d75d37194658493e045 (patch)
tree48e63df6c19f34577a9747adcc0bf0f3ae343caf /src/libs
parente97cdac9ddef51f8834e9eb32fedd44fdfac36cd (diff)
downloadgroff-git-c5772157d1136372470f5d75d37194658493e045.tar.gz
[libgroff]: Drop line # from some diagnostics.
* src/libs/libgroff/font.cpp (font::load_desc): Clear line number before emitting whole-file validity diagnostics. $ nl build/font/devutf8/DESC 1 #res 240 2 hor 24 3 vert 40 4 unitwidth 10 5 sizes 10 0 6 fonts 4 R I B BI 7 tcommand 8 postpro grotty 9 unicode $ GROFF_FONT_PATH=build/font groff -Tutf8 groff:build/font/devutf8/DESC:9: missing 'res' command groff: fatal error: invalid device 'utf8' $ build/test-groff -Tutf8 .../build/groff:.../build/font/devutf8/DESC: error: device description file missing 'res' directive .../build/groff: fatal error: cannot load 'DESC' description file for device 'utf8'
Diffstat (limited to 'src/libs')
-rw-r--r--src/libs/libgroff/font.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libs/libgroff/font.cpp b/src/libs/libgroff/font.cpp
index 6baa85b07..99aa640c3 100644
--- a/src/libs/libgroff/font.cpp
+++ b/src/libs/libgroff/font.cpp
@@ -1238,6 +1238,7 @@ bool font::load_desc()
t.lineno);
}
}
+ t.lineno = 0;
if (res == 0) {
t.error("device description file missing 'res' directive");
return false;