mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-22 20:43:02 +01:00
Replace custom routine by common logic
This commit is contained in:
parent
81f6ff0765
commit
9344289ef7
@ -40,6 +40,7 @@
|
||||
#include "../jrd/gds_proto.h"
|
||||
#include "../jrd/isc_f_proto.h"
|
||||
#include "../jrd/utl_proto.h"
|
||||
#include "../common/utils_proto.h"
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
@ -3619,15 +3620,9 @@ static int truncate_string( TEXT* string)
|
||||
* not including the terminating null.
|
||||
*
|
||||
**************************************/
|
||||
TEXT *p;
|
||||
|
||||
for (p = string; *p; p++);
|
||||
|
||||
for (p--; (p >= string) && (*p == ' '); p--);
|
||||
|
||||
*++p = 0;
|
||||
|
||||
return (p - string);
|
||||
const int len = fb_utils::name_length(string);
|
||||
string[len] = 0;
|
||||
return len;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user