From 6033e3191516f23c837b3878b00e23f0c90ed09a Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Mon, 6 Jun 2016 18:22:14 +0200 Subject: dbfp: rename dbfp_query_location_name to dbfp_query_location --- dbfp.c | 4 ++-- dbfp.h | 8 ++++---- dbfp_check.c | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/dbfp.c b/dbfp.c index b2d8074..5c54a3d 100644 --- a/dbfp.c +++ b/dbfp.c @@ -123,8 +123,8 @@ void dbfp_location_close(struct dbfp_location *location) free(location->id); } -int dbfp_query_location_name(struct dbfp *dbfp, char *input, - size_t *n, struct dbfp_location **locations) +int dbfp_query_location(struct dbfp *dbfp, char *input, size_t *n, + struct dbfp_location **locations) { int err = 0; char *input_enc = NULL; diff --git a/dbfp.h b/dbfp.h index af74f1d..82d3801 100644 --- a/dbfp.h +++ b/dbfp.h @@ -49,12 +49,12 @@ int dbfp_init(struct dbfp *dbfp, char *key); void dbfp_close(struct dbfp *dbfp); void dbfp_location_close(struct dbfp_location *location); -int dbfp_query_location_name(struct dbfp *dbfp, char *input, - size_t *n, struct dbfp_location **locations); +int dbfp_query_location(struct dbfp *dbfp, char *input, size_t *n, + struct dbfp_location **locations); void dbfp_departure_close(struct dbfp_departure *departure); int dbfp_query_departure(struct dbfp *dbfp, struct dbfp_location *location, - char *location_id, time_t time, size_t *n, - struct dbfp_departure **departures); + char *location_id, time_t time, size_t *n, + struct dbfp_departure **departures); #endif /* DBFP_H_ */ diff --git a/dbfp_check.c b/dbfp_check.c index bda63e5..b17945b 100644 --- a/dbfp_check.c +++ b/dbfp_check.c @@ -43,7 +43,7 @@ START_TEST(test_dbfp_access) err = dbfp_init(&dbfp, api_key); ck_assert_int_eq(err, 0); - err = dbfp_query_location_name(&dbfp, "", &n, &locations); + err = dbfp_query_location(&dbfp, "", &n, &locations); ck_assert_int_eq(err, 0); free(locations); @@ -62,7 +62,7 @@ START_TEST(test_dbfp_location_simple) err = dbfp_init(&dbfp, api_key); ck_assert_int_eq(err, 0); - err = dbfp_query_location_name(&dbfp, "freiburg", &n, &locations); + err = dbfp_query_location(&dbfp, "freiburg", &n, &locations); ck_assert_int_eq(err, 0); assert_location_eq(n, locations, 0, "Freiburg(Breisgau) Hbf", "008000107", 7.841173f, 47.997696f); @@ -70,7 +70,7 @@ START_TEST(test_dbfp_location_simple) dbfp_location_close(&locations[i]); free(locations); - err = dbfp_query_location_name(&dbfp, "freib", &n, &locations); + err = dbfp_query_location(&dbfp, "freib", &n, &locations); ck_assert_int_eq(err, 0); assert_location_eq(n, locations, 0, "Freiburg(Breisgau) Hbf", "008000107", 7.841173f, 47.997696f); @@ -78,7 +78,7 @@ START_TEST(test_dbfp_location_simple) dbfp_location_close(&locations[i]); free(locations); - err = dbfp_query_location_name(&dbfp, "freiburg im", &n, &locations); + err = dbfp_query_location(&dbfp, "freiburg im", &n, &locations); ck_assert_int_eq(err, 0); assert_location_eq(n, locations, 0, "Freiburg(Breisgau) Hbf", "008000107", 7.841173f, 47.997696f); -- cgit v1.2.1