Changeset 13769


Ignore:
Timestamp:
Jan 5, 2013, 5:46:12 PM (8 years ago)
Author:
jordan
Message:

(2.7x, libT) backport r13752, r13762 for #4633

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.7x/libtransmission/torrent.c

    r13741 r13769  
    20172017
    20182018#ifdef WIN32
    2019         _spawnvpe (_P_NOWAIT, script, (const char*)cmd, env);
     2019        if (_spawnvpe (_P_NOWAIT, script, (const char*)cmd, env) == -1)
     2020          tr_torerr (tor, "error executing script \"%s\": %s", cmd[0], tr_strerror (errno));
    20202021#else
    20212022        signal (SIGCHLD, onSigCHLD);
     
    20252026            for (i=0; env[i]; ++i)
    20262027                putenv (env[i]);
    2027             execvp (script, cmd);
     2028
     2029            if (execvp (script, cmd) == -1)
     2030              tr_torerr (tor, "error executing script \"%s\": %s", cmd[0], tr_strerror (errno));
     2031
    20282032            _exit (0);
    20292033        }
Note: See TracChangeset for help on using the changeset viewer.