Merge branch 'for-justin' of git://github.com/BenoitKnecht/minidlna

This commit is contained in:
Justin Maggard
2013-11-01 17:57:00 -07:00
18 changed files with 447 additions and 403 deletions

View File

@ -78,6 +78,7 @@
#include "tivo_utils.h"
#include "tivo_commands.h"
#include "clients.h"
#include "process.h"
#include "sendfile.h"
@ -1579,8 +1580,8 @@ SendResp_resizedimg(struct upnphttp * h, char * object)
#if USE_FORK
pid_t newpid = 0;
newpid = fork();
if( newpid )
newpid = process_fork();
if( newpid > 0 )
{
CloseSocket_upnphttp(h);
goto resized_error;
@ -1723,7 +1724,7 @@ SendResp_resizedimg(struct upnphttp * h, char * object)
resized_error:
sqlite3_free_table(result);
#if USE_FORK
if( !newpid )
if( newpid == 0 )
_exit(0);
#endif
}
@ -1816,8 +1817,8 @@ SendResp_dlnafile(struct upnphttp *h, char *object)
sqlite3_free_table(result);
}
#if USE_FORK
newpid = fork();
if( newpid )
newpid = process_fork();
if( newpid > 0 )
{
CloseSocket_upnphttp(h);
goto error;
@ -1958,7 +1959,7 @@ SendResp_dlnafile(struct upnphttp *h, char *object)
CloseSocket_upnphttp(h);
error:
#if USE_FORK
if( !newpid )
if( newpid == 0 )
_exit(0);
#endif
return;