Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:12.2:Update
firebird-classic
firebird-2.5.2-isqllocale.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File firebird-2.5.2-isqllocale.patch of Package firebird-classic
From: mkubecek <mkubecek@de594faa-8d1b-4a0c-9a6a-a7de5f8bf859> Date: Tue, 29 May 2012 20:14:54 +0000 Subject: isql: fix output if charset is different from locale git-svn-id: https://firebird.svn.sourceforge.net/svnroot/firebird/firebird/trunk@54565 de594faa-8d1b-4a0c-9a6a-a7de5f8bf859 --- src/isql/isql.epp | 13 ++++++++++++- 1 files changed, 12 insertions(+), 1 deletions(-) diff --git a/src/isql/isql.epp b/src/isql/isql.epp index dc0936d..4930ccf 100644 --- a/src/isql/isql.epp +++ b/src/isql/isql.epp @@ -306,7 +306,18 @@ namespace IcuUtil if (len > width) len = width; - sprintf(buffer, (right ? "%*.*s" : "%-*.*s"), width, len, str); + if (right) { + memcpy(buffer + width - len, str, len); + if (width > len) + memset(buffer, ' ', width - len); + } + else + { + memcpy(buffer, str, len); + if (width > len) + memset(buffer + len, ' ', width - len); + } + buffer[width] = '\0'; return; } -- 1.7.7
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor