X-Git-Url: https://git.toastfreeware.priv.at/gregoa/bti.git/blobdiff_plain/3773da86abc386142bf4295e55016947a09126c8..f4584ef10960213549bd55790efb9a73eef37c7d:/bti.c diff --git a/bti.c b/bti.c index 72cc953..147d44b 100644 --- a/bti.c +++ b/bti.c @@ -284,8 +284,8 @@ static CURL *curl_init(void) } /* The final place data is sent to the screen/pty/tty */ -void bti_output_line(struct session *session, xmlChar *user, xmlChar *id, - xmlChar *created, xmlChar *text) +static void bti_output_line(struct session *session, xmlChar *user, + xmlChar *id, xmlChar *created, xmlChar *text) { if (session->verbose) printf("[%s] {%s} (%.16s) %s\n", user, id, created, text); @@ -724,6 +724,11 @@ static int send_request(struct session *session) free(req_url); } + if (!reply) { + fprintf(stderr, "Error retrieving from URL (%s)\n", endpoint); + return -EIO; + } + if ((session->action != ACTION_UPDATE) && (session->action != ACTION_RETWEET)) parse_timeline(reply, session);