summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorom <om@e03df62e-2008-0410-955e-edbf42e46eb7>2006-11-19 16:19:46 +0000
committerom <om@e03df62e-2008-0410-955e-edbf42e46eb7>2006-11-19 16:19:46 +0000
commit87b531bf29e52d2f0f42b244604715f9af15b48c (patch)
tree1fe3ed7c06868273b2011d7f86f6564fe623d87e
parentca24e71f7576591dfa5d405e16e2475aba6d2386 (diff)
Also return for 7.x series > 7.3.15, this still wants testing :p (which versions actually have the functions, I'm pretty happy with the script working properly)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5778 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/modules/extra/pgsql_config.pl7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/modules/extra/pgsql_config.pl b/src/modules/extra/pgsql_config.pl
index 6e0b54baf..c0f85758a 100644
--- a/src/modules/extra/pgsql_config.pl
+++ b/src/modules/extra/pgsql_config.pl
@@ -1,4 +1,7 @@
#!/usr/bin/perl
-`pg_config --version` =~ /^.*?(\d+)\.(\d+)\.(\d+).*?$/;
-print "-D PGSQL_HAS_ESCAPECONN" if(hex(sprintf("0x%02x%02x%02x", $1, $2, $3)) >= 0x080104);
+my $s = `pg_config --version`;
+$s = shift;
+$s =~ /^.*?(\d+)\.(\d+)\.(\d+).*?$/;
+my $v = hex(sprintf("0x%02x%02x%02x", $1, $2, $3));
+print "-D PGSQL_HAS_ESCAPECONN" if(($v >= 0x080104) or (($v >= 0x07030F) and ($v < 0x080000)));