lmi-commits
[Top][All Lists]
Advanced

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

[lmi-commits] [lmi] master 4a4e616 2/4: Fix defect introduced 20050203T1


From: Greg Chicares
Subject: [lmi-commits] [lmi] master 4a4e616 2/4: Fix defect introduced 20050203T1603Z: latent abrupt termination
Date: Mon, 26 Feb 2018 18:50:50 -0500 (EST)

branch: master
commit 4a4e616357c8f28853e4da6a9c71a6c87e1dee1e
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>

    Fix defect introduced 20050203T1603Z: latent abrupt termination
    
    Fixed the defect demonstrated in the preceding commit, and discussed in
    its commit message, in the most direct way--see:
      http://lists.nongnu.org/archive/html/lmi/2018-02/msg00157.html
---
 numeric_io_traits.hpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/numeric_io_traits.hpp b/numeric_io_traits.hpp
index b6bc666..a509d79 100644
--- a/numeric_io_traits.hpp
+++ b/numeric_io_traits.hpp
@@ -95,7 +95,7 @@ inline std::string simplify_floating_point(std::string const& 
s)
   loop:
     switch(*ri)
         {
-        case '0': if(++ri != s.rend()) goto loop;
+        case '0': ++ri; goto loop;
         case '.': ++ri;
         default : ;
         }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]