aboutsummaryrefslogtreecommitdiff
path: root/contrib/pg_upgrade/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/pg_upgrade/util.c')
-rw-r--r--contrib/pg_upgrade/util.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/contrib/pg_upgrade/util.c b/contrib/pg_upgrade/util.c
index b9968e9132c..3f3a4c700d0 100644
--- a/contrib/pg_upgrade/util.c
+++ b/contrib/pg_upgrade/util.c
@@ -259,3 +259,15 @@ getErrorText(int errNum)
#endif
return strdup(strerror(errNum));
}
+
+
+/*
+ * str2uint()
+ *
+ * convert string to oid
+ */
+unsigned int
+str2uint(const char *str)
+{
+ return strtol(str, NULL, 10);
+}