From 9620638cd3a172eaf071d4f95fc77cc248d719f4 Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Sat, 14 Jan 2017 15:08:18 +0100 Subject: dbfp: use HTTPS instead of HTTP The REST API seems to be no longer available via HTTP, but only via HTTPS. Therefore the URL is changed to the HTTPS scheme, and the CURL initialization is adapted to include SSL initialization. --- dbfp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dbfp.c b/dbfp.c index 5b0960d..9bc5b78 100644 --- a/dbfp.c +++ b/dbfp.c @@ -13,7 +13,7 @@ #include #include -#define DBFP_BASE_URL "http://open-api.bahn.de/bin/rest.exe" +#define DBFP_BASE_URL "https://open-api.bahn.de/bin/rest.exe" #define DBFP_URL_FORMAT "%s/%s?authKey=%s&%s" #define DBFP_URL_LEN 8000 @@ -79,7 +79,7 @@ int dbfp_init(struct dbfp *dbfp, char *key) goto cleanup; } - curl_global_init(CURL_GLOBAL_ALL ^ CURL_GLOBAL_SSL); + curl_global_init(CURL_GLOBAL_ALL); curl = curl_easy_init(); if (!curl) { err = DBFP_ERROR_CURL; -- cgit v1.2.1