Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
bb7a3a74
Commit
bb7a3a74
authored
Mar 02, 2005
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use our own snprintf() only if NLS is enabled, and support %qd and %I64d.
parent
70d4a934
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
4 deletions
+23
-4
configure
configure
+2
-1
configure.in
configure.in
+3
-2
src/port/snprintf.c
src/port/snprintf.c
+18
-1
No files found.
configure
View file @
bb7a3a74
...
...
@@ -14527,7 +14527,8 @@ fi
# Force use of our snprintf if system's doesn't do arg control
if
test
$pgac_need_repl_snprintf
=
no
;
then
# This feature is used by NLS
if
test
"
$enable_nls
"
=
yes
-a
$pgac_need_repl_snprintf
=
no
;
then
echo
"
$as_me
:
$LINENO
: checking whether printf supports argument control"
>
&5
echo
$ECHO_N
"checking whether printf supports argument control...
$ECHO_C
"
>
&6
if
test
"
${
pgac_cv_printf_arg_control
+set
}
"
=
set
;
then
...
...
configure.in
View file @
bb7a3a74
dnl Process this file with autoconf to produce a configure script.
dnl $PostgreSQL: pgsql/configure.in,v 1.40
3 2005/02/28 20:55:18 tgl
Exp $
dnl $PostgreSQL: pgsql/configure.in,v 1.40
4 2005/03/02 14:48:22 momjian
Exp $
dnl
dnl Developers, please strive to achieve this order:
dnl
...
...
@@ -1067,7 +1067,8 @@ AC_MSG_ERROR([[
# Force use of our snprintf if system's doesn't do arg control
if test $pgac_need_repl_snprintf = no; then
# This feature is used by NLS
if test "$enable_nls" = yes -a $pgac_need_repl_snprintf = no; then
PGAC_FUNC_PRINTF_ARG_CONTROL
if test $pgac_cv_printf_arg_control != yes ; then
pgac_need_repl_snprintf=yes
...
...
src/port/snprintf.c
View file @
bb7a3a74
...
...
@@ -65,7 +65,7 @@
* causing nasty effects.
**************************************************************/
/*static char _id[] = "$PostgreSQL: pgsql/src/port/snprintf.c,v 1.1
2 2005/03/02 05:22
:22 momjian Exp $";*/
/*static char _id[] = "$PostgreSQL: pgsql/src/port/snprintf.c,v 1.1
3 2005/03/02 14:48
:22 momjian Exp $";*/
int
snprintf
(
char
*
str
,
size_t
count
,
const
char
*
fmt
,...);
int
vsnprintf
(
char
*
str
,
size_t
count
,
const
char
*
fmt
,
va_list
args
);
...
...
@@ -259,6 +259,23 @@ dopr(char *buffer, const char *format, va_list args, char *end)
else
longflag
=
1
;
goto
nextch
;
/*
* We might export this to client apps so we should
* support 'qd' and 'I64d'(MinGW) also in case the
* native version does.
*/
case
'q'
:
longlongflag
=
1
;
longflag
=
1
;
goto
nextch
;
case
'I'
:
if
(
*
(
format
+
1
)
==
'6'
&&
*
(
format
+
2
)
==
'4'
)
{
format
+=
2
;
longlongflag
=
1
;
longflag
=
1
;
goto
nextch
;
}
case
'u'
:
case
'U'
:
/* fmtnum(value,base,dosign,ljust,len,zpad,&output) */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment