Revision c60112f2 libavformat/tcp.c

View differences:

libavformat/tcp.c
64 64
    snprintf(portstr, sizeof(portstr), "%d", port);
65 65
    ret = getaddrinfo(hostname, portstr, &hints, &ai);
66 66
    if (ret) {
67
        av_log(NULL, AV_LOG_ERROR,
67
        av_log(h, AV_LOG_ERROR,
68 68
               "Failed to resolve hostname %s: %s\n",
69 69
               hostname, gai_strerror(ret));
70 70
        return AVERROR(EIO);
......
119 119
        optlen = sizeof(ret);
120 120
        getsockopt (fd, SOL_SOCKET, SO_ERROR, &ret, &optlen);
121 121
        if (ret != 0) {
122
            av_log(NULL, AV_LOG_ERROR,
122
            av_log(h, AV_LOG_ERROR,
123 123
                   "TCP connection to %s:%d failed: %s\n",
124 124
                   hostname, port, strerror(ret));
125 125
            goto fail;

Also available in: Unified diff