Commit 4be5ecbd authored by massiot's avatar massiot

* dvblastctl.c: Fix a gcc warning.


git-svn-id: svn://svn.videolan.org/dvblast/trunk@13 55d3f8b6-4a41-4d2d-a900-313d1436a5b8
parent d839dbfb
......@@ -48,7 +48,7 @@ void usage()
int main( int i_argc, char **ppsz_argv )
{
char psz_client_socket[FILENAME_MAX];
char psz_client_socket[L_tmpnam];
char *psz_srv_socket = NULL;
int i_fd, i_mask;
int i = 65535;
......@@ -104,7 +104,12 @@ int main( int i_argc, char **ppsz_argv )
usage();
#warning expect brain-dead gcc warning about tmpnam here
tmpnam(psz_client_socket);
if ( tmpnam(psz_client_socket) == NULL )
{
msg_Err( NULL, "cannot build UNIX socket (%s)", strerror(errno) );
return -1;
}
if ( (i_fd = socket( AF_UNIX, SOCK_DGRAM, 0 )) < 0 )
{
msg_Err( NULL, "cannot create UNIX socket (%s)", strerror(errno) );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment