service-file.patch

text/x-patch

Filename: service-file.patch
Type: text/x-patch
Part: 0
Message: Re: unknown libpq service entries ignored

Patch

Format: unified
File+
src/interfaces/libpq/fe-connect.c 7 0
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index 011ebab..b322f8d 100644
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -3189,6 +3189,13 @@ parseServiceInfo(PQconninfoOption *options, PQExpBuffer errorMessage)
 		fclose(f);
 	}
 
+	if (!group_found)
+	{
+		printfPQExpBuffer(errorMessage,
+						  libpq_gettext("ERROR: service \"%s\" not found\n"), service);
+		return 3;
+	}
+
 	return 0;
 }