Skip to content

Commit d4b799f

Browse files
committed
avoid dangling data during shutdown
1 parent 0acba59 commit d4b799f

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

main/SAPI.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,18 +507,23 @@ SAPI_API void sapi_deactivate_module(void)
507507
}
508508
if (SG(request_info).auth_user) {
509509
efree(SG(request_info).auth_user);
510+
SG(request_info).auth_user = NULL;
510511
}
511512
if (SG(request_info).auth_password) {
512513
efree(SG(request_info).auth_password);
514+
SG(request_info).auth_password = NULL;
513515
}
514516
if (SG(request_info).auth_digest) {
515517
efree(SG(request_info).auth_digest);
518+
SG(request_info).auth_digest = NULL;
516519
}
517520
if (SG(request_info).content_type_dup) {
518521
efree(SG(request_info).content_type_dup);
522+
SG(request_info).content_type_dup = NULL;
519523
}
520524
if (SG(request_info).current_user) {
521525
efree(SG(request_info).current_user);
526+
SG(request_info).current_user = NULL;
522527
}
523528
if (sapi_module.deactivate) {
524529
sapi_module.deactivate();

0 commit comments

Comments
 (0)