Fixed wrong file open mode.

This commit is contained in:
Markus Makela 2015-08-24 16:04:08 +03:00
parent 0a33174803
commit 063c8f904a

View File

@ -2057,7 +2057,7 @@ bool pid_file_exists()
{
int fd, b;
if((fd = open(pathbuf, O_RDONLY)) == -1)
if((fd = open(pathbuf, O_RDWR)) == -1)
{
char* logerr = "Failed to open PID file '%s'.";
snprintf(logbuf,sizeof(logbuf),logerr,pathbuf);