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
b70999d0
Commit
b70999d0
authored
Sep 09, 2004
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make TZNAME_GLOBAL for reference to tzname global variable.
parent
f62901ca
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
5 deletions
+6
-5
src/include/port.h
src/include/port.h
+3
-2
src/interfaces/ecpg/pgtypeslib/dt_common.c
src/interfaces/ecpg/pgtypeslib/dt_common.c
+2
-2
src/interfaces/ecpg/pgtypeslib/timestamp.c
src/interfaces/ecpg/pgtypeslib/timestamp.c
+1
-1
No files found.
src/include/port.h
View file @
b70999d0
...
...
@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2004, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $PostgreSQL: pgsql/src/include/port.h,v 1.5
8 2004/09/08 19:43:07
momjian Exp $
* $PostgreSQL: pgsql/src/include/port.h,v 1.5
9 2004/09/09 00:24:10
momjian Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -183,9 +183,10 @@ extern int win32_open(const char *, int,...);
/* Global variable holding time zone information. */
#if !defined(__CYGWIN__)
#define TIMEZONE_GLOBAL timezone
#define TZNAME_GLOBAL tzname
#else
#define TIMEZONE_GLOBAL _timezone
#define
tzname _tzname
/* should be in time.h? */
#define
TZNAME_GLOBAL _tzname
#endif
extern
int
copydir
(
char
*
fromdir
,
char
*
todir
);
...
...
src/interfaces/ecpg/pgtypeslib/dt_common.c
View file @
b70999d0
...
...
@@ -1065,8 +1065,8 @@ abstime2tm(AbsoluteTime _time, int *tzp, struct tm * tm, char **tzn)
* case it contains an error message, which doesn't fit in the
* buffer
*/
StrNCpy
(
*
tzn
,
tzname
[
tm
->
tm_isdst
],
MAXTZLEN
+
1
);
if
(
strlen
(
tzname
[
tm
->
tm_isdst
])
>
MAXTZLEN
)
StrNCpy
(
*
tzn
,
TZNAME_GLOBAL
[
tm
->
tm_isdst
],
MAXTZLEN
+
1
);
if
(
strlen
(
TZNAME_GLOBAL
[
tm
->
tm_isdst
])
>
MAXTZLEN
)
tm
->
tm_isdst
=
-
1
;
}
}
...
...
src/interfaces/ecpg/pgtypeslib/timestamp.c
View file @
b70999d0
...
...
@@ -223,7 +223,7 @@ timestamp2tm(timestamp dt, int *tzp, struct tm * tm, fsec_t *fsec, char **tzn)
#elif defined(HAVE_INT_TIMEZONE)
*
tzp
=
((
tm
->
tm_isdst
>
0
)
?
(
TIMEZONE_GLOBAL
-
3600
)
:
TIMEZONE_GLOBAL
);
if
(
tzn
!=
NULL
)
*
tzn
=
tzname
[(
tm
->
tm_isdst
>
0
)];
*
tzn
=
TZNAME_GLOBAL
[(
tm
->
tm_isdst
>
0
)];
#endif
#else
/* not (HAVE_TM_ZONE || HAVE_INT_TIMEZONE) */
...
...
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