]> git.street.me.uk Git - andy/viking.git/blobdiff - src/geonamessearch.c
When manually creating a track, automatically give it a default name.
[andy/viking.git] / src / geonamessearch.c
index ae48977e1cb02c0b0dbc63041d352c4f3f18af10..5e521cf29aea149629504a7c91a9c879fb5eaffe 100644 (file)
@@ -35,7 +35,6 @@
 #include "curl_download.h"
 
 #define GEONAMES_WIKIPEDIA_URL_FMT "http://ws.geonames.org/wikipediaBoundingBoxJSON?formatted=true&north=%s&south=%s&east=%s&west=%s"
-#define GEONAMES_SEARCH_URL_FMT "http://ws.geonames.org/searchJSON?formatted=true&style=medium&maxRows=10&lang=en&q=%s"
 #define GEONAMES_COUNTRY_PATTERN "\"countryName\": \""
 #define GEONAMES_LONGITUDE_PATTERN "\"lng\": "
 #define GEONAMES_NAME_PATTERN "\"name\": \""
@@ -399,7 +398,7 @@ gchar *download_url(gchar *uri)
   tmp_file = fdopen(tmp_fd, "r+");
 
   // TODO: curl may not be available
-  if (curl_download_uri(uri, tmp_file, NULL)) {  // error
+  if (curl_download_uri(uri, tmp_file, NULL, 0, NULL)) {  // error
     fclose(tmp_file);
     tmp_file = NULL;
     g_remove(tmpname);