diff options
author | Paolo Carlini <pcarlini@suse.de> | 2004-06-28 11:18:03 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2004-06-28 11:18:03 +0000 |
commit | 2d91a076cc696350b1256e791079d6de02af6d6e (patch) | |
tree | 44fcd205f556d4b9b10c0555c82d5093d42b61f3 | |
parent | e4cb0c044181cd1fb316350fb2b44ea5191bce1a (diff) | |
download | gcc-2d91a076cc696350b1256e791079d6de02af6d6e.zip gcc-2d91a076cc696350b1256e791079d6de02af6d6e.tar.gz gcc-2d91a076cc696350b1256e791079d6de02af6d6e.tar.bz2 |
localename.cc (locale::_Impl::_Impl): Slightly improve the algorithm used to name the categories.
2004-06-28 Paolo Carlini <pcarlini@suse.de>
* src/localename.cc (locale::_Impl::_Impl): Slightly improve
the algorithm used to name the categories.
From-SVN: r83778
-rw-r--r-- | libstdc++-v3/ChangeLog | 5 | ||||
-rw-r--r-- | libstdc++-v3/src/localename.cc | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 904d184..d0c64e4 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2004-06-28 Paolo Carlini <pcarlini@suse.de> + + * src/localename.cc (locale::_Impl::_Impl): Slightly improve + the algorithm used to name the categories. + 2004-06-28 Paolo Bonzini <bonzini@gnu.org> * include/Makefile.am: Give a .gch extension to diff --git a/libstdc++-v3/src/localename.cc b/libstdc++-v3/src/localename.cc index e90e847..f9c7a82 100644 --- a/libstdc++-v3/src/localename.cc +++ b/libstdc++-v3/src/localename.cc @@ -209,11 +209,11 @@ namespace std } else { - const char* __beg = __s; + const char* __end = __s; for (size_t __i = 0; __i < _S_categories_size; ++__i) { - __beg = std::strchr(__beg, '=') + 1; - const char* __end = std::strchr(__beg, ';'); + const char* __beg = std::strchr(__end + 1, '=') + 1; + __end = std::strchr(__beg, ';'); if (!__end) __end = __s + __len; _M_names[__i] = new char[__end - __beg + 1]; |