[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[3dldf] 01/01: fix int/char mixup (Closes: #760701)



This is an automated email from the git hooks/post-receive script.

preining pushed a commit to branch master
in repository 3dldf.

commit 7ef2e64476f112da37196093902173e11edad714
Author: Norbert Preining <preining@debian.org>
Date:   Tue Jun 13 08:39:19 2017 +0900

    fix int/char mixup (Closes: #760701)
---
 debian/changelog                   |  7 ++++
 debian/patches/fix-char-not-signed | 65 ++++++++++++++++++++++++++++++++++++++
 debian/patches/series              |  1 +
 3 files changed, 73 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 2815ccb..116edce 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+3dldf (2.0.3+dfsg-6) unstable; urgency=medium
+
+  * fix int/char mixup (Closes: #760701)
+    Thanks to Edmund Grimley Evans
+
+ -- Norbert Preining <preining@debian.org>  Tue, 13 Jun 2017 08:38:00 +0900
+
 3dldf (2.0.3+dfsg-5) unstable; urgency=medium
 
   * fix FTBFS with newer gcc, patch thanks to Adrian Bunk (Closes: #811794)
diff --git a/debian/patches/fix-char-not-signed b/debian/patches/fix-char-not-signed
new file mode 100644
index 0000000..38e64ea
--- /dev/null
+++ b/debian/patches/fix-char-not-signed
@@ -0,0 +1,65 @@
+bug 760701
+From Edmund Grimley Evans
+The pattern of failures certainly looks like that of a program that
+assumes char is signed... and, indeed, this seems to fix it:
+
+  - In io.web, change the return type of get() and peek() from char to int.
+
+  - In scan.web, change the type of prev_char, curr_char and next_char from char to int.
+
+---
+ src/io.web   |    8 ++++----
+ src/scan.web |    6 +++---
+ 2 files changed, 7 insertions(+), 7 deletions(-)
+
+--- 3dldf.orig/src/io.web
++++ 3dldf/src/io.web
+@@ -3265,14 +3265,14 @@
+ \ENDLOG 
+ 
+ @<Declare |Scanner_Type| functions@>=
+-char
++int
+ get() const;
+ 
+ 
+ @q ****** (6) Definition. @>
+ @
+ @<Define |Scanner_Type| functions@>=
+-char
++int
+ Scanner_Type::get() const
+ {
+   return in->stream_ptr->get();
+@@ -3285,14 +3285,14 @@
+ \ENDLOG 
+ 
+ @<Declare |Scanner_Type| functions@>=
+-char
++int
+ peek() const;
+ 
+ 
+ @q ****** (6) Definition. @>
+ @
+ @<Define |Scanner_Type| functions@>=
+-char
++int
+ Scanner_Type::peek() const
+ {
+   return in->stream_ptr->peek();
+--- 3dldf.orig/src/scan.web
++++ 3dldf/src/scan.web
+@@ -1211,9 +1211,9 @@
+   unsigned int start_column;
+   unsigned int curr_column;
+ 
+-  char prev_char;  
+-  char curr_char = EOF;
+-  char next_char = EOF;
++  int prev_char;  
++  int curr_char = EOF;
++  int next_char = EOF;
+ 
+   string curr_token_string = "";
+   unsigned int curr_catcode;
diff --git a/debian/patches/series b/debian/patches/series
index 7978b62..724a0c9 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -8,3 +8,4 @@ upstream-sys-std_numeric_limits.patch
 debianization-dfsg.patch
 debianization.patch
 debianization-manpages.patch
+fix-char-not-signed

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-tex/3dldf.git


Reply to: