Author: sebor
Date: Mon Mar 26 17:42:53 2007
New Revision: 522681
URL: http://svn.apache.org/viewvc?view=rev&rev=522681
Log:
2007-03-26 Martin Sebor <[EMAIL PROTECTED]>
STDCXX-62
* _money_get.cc (_C_get): Checked for iterator equality to end before
dereferencing it.
Modified:
incubator/stdcxx/trunk/include/loc/_money_get.cc
Modified: incubator/stdcxx/trunk/include/loc/_money_get.cc
URL:
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/loc/_money_get.cc?view=diff&rev=522681&r1=522680&r2=522681
==============================================================================
--- incubator/stdcxx/trunk/include/loc/_money_get.cc (original)
+++ incubator/stdcxx/trunk/include/loc/_money_get.cc Mon Mar 26 17:42:53 2007
@@ -6,16 +6,23 @@
*
***************************************************************************
*
- * Copyright (c) 1994-2005 Quovadx, Inc., acting through its Rogue Wave
- * Software division. Licensed under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance with the
- * License. You may obtain a copy of the License at
- * http://www.apache.org/licenses/LICENSE-2.0. Unless required by
- * applicable law or agreed to in writing, software distributed under
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
- * CONDITIONS OF ANY KIND, either express or implied. See the License
- * for the specific language governing permissions and limitations under
- * the License.
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ *
+ * Copyright 2001-2006 Rogue Wave Software.
*
**************************************************************************/
@@ -156,6 +163,11 @@
}
case /* '\3' */ money_base::sign: {
+
+ if (__it == __end) {
+ __ebits |= _RW::__rw_failbit;
+ break;
+ }
const char_type __c = *__it;