summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorrofl0r <retnyg@gmx.net>2012-12-25 06:03:24 +0100
committerrofl0r <retnyg@gmx.net>2012-12-25 06:03:48 +0100
commit92e039f526ef7988a9b8cf500fd45a3a5b045ced (patch)
treeeb6f9945eec57d64c0eaf0c2cc885e5acf4311c2 /Makefile
parentddf6dfea27f4a7d57ed73a4f5a146b6b704e9103 (diff)
downloadgettext-tiny-92e039f526ef7988a9b8cf500fd45a3a5b045ced.tar.gz
fix assertion error on huge string found in gnumericv0.0.2
the culprit is: gnumeric-1.10.17/po-functions/dz.po basically the code was wrongly checking for the end of the convert buffer, instead of the line buffer. this is no problem per se because the line buffer gets reset more often, but when the convertbuffer is bigger (like after this change) it wouldnt work correctly. i put the convert_buf functions into a separate translation unit and renamed them to escape and unescape to make it more clear what they're doing. also new: size checks for the escape functions. currently it will silently truncate the strings when the buffer runs out of space. this is sufficient for no-op style, but should be fixed at some point.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 3 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index c706463..4028bcf 100644
--- a/Makefile
+++ b/Makefile
@@ -7,6 +7,7 @@ sysconfdir=$(prefix)/etc
LIBSRC = $(sort $(wildcard libintl/*.c))
PROGSRC = $(sort $(wildcard src/*.c))
+PARSEROBJS = src/poparser.o src/StringEscape.o
PROGOBJS = $(PROGSRC:.c=.o)
LIBOBJS = $(LIBSRC:.c=.o)
OBJS = $(PROGOBJS) $(LIBOBJS)
@@ -46,10 +47,10 @@ libintl.a: $(LIBOBJS)
$(RANLIB) $@
msgmerge: $(OBJS)
- $(CC) $(LDFLAGS) -static -o $@ src/msgmerge.o src/poparser.o
+ $(CC) $(LDFLAGS) -static -o $@ src/msgmerge.o $(PARSEROBJS)
msgfmt: $(OBJS)
- $(CC) $(LDFLAGS) -static -o $@ src/msgfmt.o src/poparser.o
+ $(CC) $(LDFLAGS) -static -o $@ src/msgfmt.o $(PARSEROBJS)
xgettext:
cp src/xgettext.sh ./xgettext