Show More
@@ -29,11 +29,11 def runservice(opts, parentfn=None, init | |||
|
29 | 29 | def writepid(pid): |
|
30 | 30 | if opts['pid_file']: |
|
31 | 31 | if appendpid: |
|
32 | mode = 'a' | |
|
32 | mode = 'ab' | |
|
33 | 33 | else: |
|
34 | mode = 'w' | |
|
34 | mode = 'wb' | |
|
35 | 35 | fp = open(opts['pid_file'], mode) |
|
36 | fp.write(str(pid) + '\n') | |
|
36 | fp.write(str(pid).encode('latin1') + '\n') | |
|
37 | 37 | fp.close() |
|
38 | 38 | |
|
39 | 39 | if opts['daemon'] and not opts['daemon_postexec']: |
General Comments 0
You need to be logged in to leave comments.
Login now