From eb990a2b9efff853d0c68a9cf902b1df23498540 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Thu, 15 Mar 2012 21:17:19 +0200 Subject: Add const qualifier to tzn returned by timestamp2tm() The tzn value might come from tm->tm_zone, which libc declares as const, so it's prudent that the upper layers know about this as well. --- src/include/utils/timestamp.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/include/utils') diff --git a/src/include/utils/timestamp.h b/src/include/utils/timestamp.h index 2eae95efac1..56699247668 100644 --- a/src/include/utils/timestamp.h +++ b/src/include/utils/timestamp.h @@ -222,7 +222,7 @@ extern const char *timestamptz_to_str(TimestampTz t); extern int tm2timestamp(struct pg_tm * tm, fsec_t fsec, int *tzp, Timestamp *dt); extern int timestamp2tm(Timestamp dt, int *tzp, struct pg_tm * tm, - fsec_t *fsec, char **tzn, pg_tz *attimezone); + fsec_t *fsec, const char **tzn, pg_tz *attimezone); extern void dt2time(Timestamp dt, int *hour, int *min, int *sec, fsec_t *fsec); extern int interval2tm(Interval span, struct pg_tm * tm, fsec_t *fsec); -- cgit v1.2.3