diff options
author | Marc Hoersken <info@marc-hoersken.de> | 2021-07-16 12:23:03 +0200 |
---|---|---|
committer | Marc Hoersken <info@marc-hoersken.de> | 2021-07-29 08:08:07 +0200 |
commit | c34bd93f60d0dfc128c51cbcde8b7e03dcdfdc6d (patch) | |
tree | c54bc9fd498d396029430102ed991714ce3e6020 /tests/smbserver.py | |
parent | 4d680e4a8fa578b00bb56ba7e9a7fd2f926b2beb (diff) | |
download | curl-c34bd93f60d0dfc128c51cbcde8b7e03dcdfdc6d.tar.gz |
tests/*server.py: remove pidfile on server termination
Avoid pidfile leaking/laying around after server already exited.
Reviewed-by: Daniel Stenberg
Closes #7506
Diffstat (limited to 'tests/smbserver.py')
-rwxr-xr-x | tests/smbserver.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/smbserver.py b/tests/smbserver.py index a49023b0f..5f13c2f8a 100755 --- a/tests/smbserver.py +++ b/tests/smbserver.py @@ -391,5 +391,8 @@ if __name__ == '__main__': log.exception(e) rc = ScriptRC.EXCEPTION + if options.pidfile and os.path.isfile(options.pidfile): + os.unlink(options.pidfile) + log.info("[SMB] Returning %d", rc) sys.exit(rc) |