diff --git a/ChangeLog b/ChangeLog index 181fdc6..c73700a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2020-04-06 Wolfgang Lux + + * SQLClient.m(initWithConfiguration:name:pool:): Eventually + reconfigure a client connection that gets reused. + 2020-03-21 Richard Frith-Macdonald * Postgres.m: Don't attempt to establish connection before query or diff --git a/SQLClient.m b/SQLClient.m index b724445..0c6c74d 100644 --- a/SQLClient.m +++ b/SQLClient.m @@ -1803,6 +1803,18 @@ static int poolConnections = 0; { [self release]; self = [existing retain]; + + if ([conf isKindOfClass: [NSUserDefaults class]] == NO) + { + /* If the configuration object is not the user defaults + * make sure to update the existing connnection's configuration. + */ + n = [NSNotification + notificationWithName: NSUserDefaultsDidChangeNotification + object: conf + userInfo: nil]; + [self _configure: n]; + } } [clientsLock unlock];