Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed #6175 -- Use os._exit() instead of sys.exit() in child processe…

…s. Based

on a patch from Tyson Clugg.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@7290 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 4b9497c3f13d9fb410d552cfceaa98eafb2ffa10 1 parent 1b331f6
Malcolm Tredinnick authored March 18, 2008

Showing 1 changed file with 2 additions and 2 deletions. Show diff stats Hide diff stats

  1. 4  django/utils/daemonize.py
4  django/utils/daemonize.py
@@ -18,10 +18,10 @@ def become_daemon(our_home_dir='.', out_log='/dev/null', err_log='/dev/null'):
18 18
         # Second fork
19 19
         try:
20 20
             if os.fork() > 0:
21  
-                sys.exit(0)
  21
+                os._exit(0)
22 22
         except OSError, e:
23 23
             sys.stderr.write("fork #2 failed: (%d) %s\n" % (e.errno, e.strerror))
24  
-            sys.exit(1)
  24
+            os._exit(1)
25 25
 
26 26
         si = open('/dev/null', 'r')
27 27
         so = open(out_log, 'a+', 0)

0 notes on commit 4b9497c

Please sign in to comment.
Something went wrong with that request. Please try again.