@@ -7846,8 +7846,10 @@ static void *wsgi_deadlock_thread(apr_thread_t *thd, void *data)
78467846 while (1 ) {
78477847 apr_sleep (apr_time_from_sec (1 ));
78487848
7849- gilstate = PyGILState_Ensure ();
7850- PyGILState_Release (gilstate );
7849+ if (!wsgi_daemon_shutdown ) {
7850+ gilstate = PyGILState_Ensure ();
7851+ PyGILState_Release (gilstate );
7852+ }
78517853
78527854 apr_thread_mutex_lock (wsgi_monitor_lock );
78537855 wsgi_deadlock_shutdown_time = apr_time_now ();
@@ -9204,8 +9206,7 @@ static apr_status_t wsgi_socket_connect_un(apr_socket_t *sock,
92049206 }
92059207
92069208 do {
9207- rv = connect (rawsock , (struct sockaddr * )sa ,
9208- sizeof (* sa ) + strlen (sa -> sun_path ));
9209+ rv = connect (rawsock , (struct sockaddr * )sa , sizeof (* sa ));
92099210 } while (rv == -1 && errno == EINTR );
92109211
92119212 if ((rv == -1 ) && (errno == EINPROGRESS || errno == EALREADY )
@@ -9249,7 +9250,7 @@ static int wsgi_connect_daemon(request_rec *r, WSGIDaemonSocket *daemon)
92499250
92509251 memset (& addr , 0 , sizeof (addr ));
92519252 addr .sun_family = AF_UNIX ;
9252- apr_cpystrn (addr .sun_path , daemon -> socket_path , sizeof addr .sun_path );
9253+ apr_cpystrn (addr .sun_path , daemon -> socket_path , sizeof ( addr .sun_path ) );
92539254
92549255 start_time = apr_time_now ();
92559256
0 commit comments