summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorTom Lane2019-04-28 16:45:55 +0000
committerTom Lane2019-04-28 16:45:55 +0000
commite481d26285b160058b093588e062cf3071fea192 (patch)
treebb325e77bd8e37dcc14fe6749961077719e2682b /src/test
parentac862376037727e744f25030bd8b6090c707247b (diff)
Clean up minor warnings from buildfarm.
Be more consistent about use of XXXGetDatum macros in new jsonpath code. This is mostly to avoid having code that looks randomly different from everyplace else that's doing the exact same thing. In pg_regress.c, avoid an unreferenced-function warning from compilers that don't understand pg_attribute_unused(). Putting the function inside the same #ifdef as its only caller is more straightforward coding anyway. In be-secure-openssl.c, avoid use of pg_attribute_unused() on a label. That's pretty creative, but there's no good reason to suppose that it's portable, and there's absolutely no need to use goto's here in the first place. (This wasn't actually causing any buildfarm complaints, but it's new code in v12 so it has no portability track record.)
Diffstat (limited to 'src/test')
-rw-r--r--src/test/regress/pg_regress.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/test/regress/pg_regress.c b/src/test/regress/pg_regress.c
index 189abbbdf37..0902b1fa97a 100644
--- a/src/test/regress/pg_regress.c
+++ b/src/test/regress/pg_regress.c
@@ -881,7 +881,9 @@ initialize_environment(void)
load_resultmap();
}
-pg_attribute_unused()
+#ifdef ENABLE_SSPI
+
+/* support for config_sspi_auth() */
static const char *
fmtHba(const char *raw)
{
@@ -904,7 +906,6 @@ fmtHba(const char *raw)
return ret;
}
-#ifdef ENABLE_SSPI
/*
* Get account and domain/realm names for the current user. This is based on
* pg_SSPI_recvauth(). The returned strings use static storage.
@@ -1072,7 +1073,8 @@ config_sspi_auth(const char *pgdata)
accountname, domainname, fmtHba(sl->str)) >= 0);
CW(fclose(ident) == 0);
}
-#endif
+
+#endif /* ENABLE_SSPI */
/*
* Issue a command via psql, connecting to the specified database