summaryrefslogtreecommitdiff
path: root/contrib/string
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/string')
-rw-r--r--contrib/string/Makefile9
-rw-r--r--contrib/string/string_io.c11
-rw-r--r--contrib/string/string_io.h9
-rw-r--r--contrib/string/string_io.sql.in4
4 files changed, 17 insertions, 16 deletions
diff --git a/contrib/string/Makefile b/contrib/string/Makefile
index ea42cfa91b..879fd2387f 100644
--- a/contrib/string/Makefile
+++ b/contrib/string/Makefile
@@ -1,6 +1,7 @@
#-------------------------------------------------------------------------
#
# Makefile --
+#
# Makefile for string I/O module.
#
#-------------------------------------------------------------------------
@@ -19,6 +20,8 @@ CFLAGS += $(INCLUDE_OPT) $(CFLAGS_SL)
MODNAME = string_io
+SQLDEFS = $(MODNAME).sql
+
MODULE = $(MODNAME)$(DLSUFFIX)
MODDIR = $(LIBDIR)/modules
@@ -29,12 +32,12 @@ all: module sql
module: $(MODULE)
-sql: $(MODNAME).sql
+sql: $(SQLDEFS)
-install: $(MODULE) $(MODDIR) $(SQLDIR)
+install: $(MODULE) $(SQLDEFS) $(MODDIR) $(SQLDIR)
cp -p $(MODULE) $(MODDIR)/
strip $(MODDIR)/$(MODULE)
- cp -p $(MODNAME).sql $(SQLDIR)/
+ cp -p $(SQLDEFS) $(SQLDIR)/
$(MODDIR):
mkdir -p $@
diff --git a/contrib/string/string_io.c b/contrib/string/string_io.c
index a83203887c..f28968cbe5 100644
--- a/contrib/string/string_io.c
+++ b/contrib/string/string_io.c
@@ -23,7 +23,7 @@
#define ISO8859
#define MIN(x, y) ((x) < (y) ? (x) : (y))
-#define VALUE(char) ((char) - '0')
+#define VALUE(char) ((char) - '0')
#define DIGIT(val) ((val) + '0')
#define ISOCTAL(c) (((c) >= '0') && ((c) <= '7'))
#ifndef ISO8859
@@ -352,15 +352,14 @@ c_charin(char *str)
{
return (string_input(str, 1, 0, NULL));
}
-
#endif
/* end of file */
/*
- * Local variables:
- * tab-width: 4
- * c-indent-level: 4
- * c-basic-offset: 4
+ * Local Variables:
+ * tab-width: 4
+ * c-indent-level: 4
+ * c-basic-offset: 4
* End:
*/
diff --git a/contrib/string/string_io.h b/contrib/string/string_io.h
index b4a900bbb9..b1d2b7e2c2 100644
--- a/contrib/string/string_io.h
+++ b/contrib/string/string_io.h
@@ -14,15 +14,14 @@ char *c_varcharout(char *s);
#if 0
struct varlena *c_textin(char *str);
char *c_char16in(char *str);
-
#endif
#endif
/*
- * Local variables:
- * tab-width: 4
- * c-indent-level: 4
- * c-basic-offset: 4
+ * Local Variables:
+ * tab-width: 4
+ * c-indent-level: 4
+ * c-basic-offset: 4
* End:
*/
diff --git a/contrib/string/string_io.sql.in b/contrib/string/string_io.sql.in
index a1fafbc3ae..2a15e4b535 100644
--- a/contrib/string/string_io.sql.in
+++ b/contrib/string/string_io.sql.in
@@ -40,7 +40,7 @@ create function c_mode() returns text
update pg_type set typoutput=''c_textout'' where typname=''text'';
update pg_type set typoutput=''c_textout'' where typname=''unknown'';
update pg_type set typoutput=''c_varcharout'' where typname=''varchar'';
- select ''c_mode''::text'
+ select ''c_mode''::text;'
language 'sql';
-- Define a function which restores the standard routines for char types.
@@ -55,7 +55,7 @@ create function pg_mode() returns text
update pg_type set typoutput=''textout'' where typname=''text'';
update pg_type set typoutput=''textout'' where typname=''unknown'';
update pg_type set typoutput=''varcharout'' where typname=''varchar'';
- select ''pg_mode''::text'
+ select ''pg_mode''::text;'
language 'sql';
-- Use these to do the changes manually.