mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-07-11 22:20:49 +02:00
additional error checking for declare; changes for MSYS32; add support for unlocked-io stdio functions; several C23 changes
This commit is contained in:
+7
-1
@@ -263,7 +263,13 @@ strip_trailing (char *string, int len, int newlines_only)
|
||||
{
|
||||
if ((newlines_only && string[len] == '\n') ||
|
||||
(!newlines_only && whitespace (string[len])))
|
||||
len--;
|
||||
{
|
||||
len--;
|
||||
#ifdef __MSYS__
|
||||
if (newlines_only && string[len + 1] == '\n' && string[len] == '\r')
|
||||
len--;
|
||||
#endif
|
||||
}
|
||||
else
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user