Commit 9069ac95 authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

cfortran.h::kill_trailing: wrong result with gcc -O3, use prama for -O2 (bug fix)

parent b1034dce
2013-04-23 Uwe Schulzweida <Uwe.Schulzweida@zmaw.de>
* cfortran.h::kill_trailing: wrong result with gcc -O3, use prama for -O2 (bug fix) [report: Luis Kornblueh]
* vlistXXXAttTxt: use cdi fortran datatype CBUF (char *) for the last argument (bug fix) [report: Luis Kornblueh]
2013-04-19 Uwe Schulzweida <Uwe.Schulzweida@zmaw.de>
......
......@@ -461,6 +461,8 @@ for (i=0; i<sizeofcstr/elem_len; i++) {
} return cstr; }
/* kill the trailing char t's in string s. */
#pragma GCC push_options
#pragma GCC optimize ("O2")
#ifndef __CF__KnR
static char *kill_trailing(char *s, char t)
#else
......@@ -472,6 +474,7 @@ if (e>s) { /* Need this to handle NULL string.*/
while (e>s && *--e==t); /* Don't follow t's past beginning. */
e[*e==t?0:1] = '\0'; /* Handle s[0]=t correctly. */
} return s; }
#pragma GCC pop_options
/* kill_trailingn(s,t,e) will kill the trailing t's in string s. e normally
points to the terminating '\0' of s, but may actually point to anywhere in s.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment