summaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/timestamp.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2009-05-26 02:17:50 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2009-05-26 02:17:50 +0000
commit99bf328237d89e0fd22821a940d4af0506353218 (patch)
treeaeed09d9ca32b894070046f6d32ef98280107c21 /src/backend/utils/adt/timestamp.c
parent8af641ac1f5c6972f9f282c1ab54f6fe4ed05a52 (diff)
Remove the useless and rather inconsistent return values of EncodeDateOnly,
EncodeTimeOnly, EncodeDateTime, EncodeInterval. These don't have any good reason to fail, and their callers were mostly not checking anyway.
Diffstat (limited to 'src/backend/utils/adt/timestamp.c')
-rw-r--r--src/backend/utils/adt/timestamp.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/backend/utils/adt/timestamp.c b/src/backend/utils/adt/timestamp.c
index 26fd570d672..507f74a71cd 100644
--- a/src/backend/utils/adt/timestamp.c
+++ b/src/backend/utils/adt/timestamp.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/utils/adt/timestamp.c,v 1.198 2009/04/04 04:53:25 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/adt/timestamp.c,v 1.199 2009/05/26 02:17:50 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -684,8 +684,7 @@ interval_out(PG_FUNCTION_ARGS)
if (interval2tm(*span, tm, &fsec) != 0)
elog(ERROR, "could not convert interval to tm");
- if (EncodeInterval(tm, fsec, IntervalStyle, buf) != 0)
- elog(ERROR, "could not format interval");
+ EncodeInterval(tm, fsec, IntervalStyle, buf);
result = pstrdup(buf);
PG_RETURN_CSTRING(result);