From af806756a46b2360d13b33e82ae7e55c357088e2 Mon Sep 17 00:00:00 2001 From: Rob Norris Date: Tue, 17 Jan 2012 20:22:16 +0000 Subject: [PATCH] Restore compilation of test program gpx2gpx. Code tidy up in commit a7cd93ac0848d91f1cf133a934c473cc4054c532, means direct layer functions are no longer available. --- test/gpx2gpx.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/test/gpx2gpx.c b/test/gpx2gpx.c index 4799dca1..15521c5f 100644 --- a/test/gpx2gpx.c +++ b/test/gpx2gpx.c @@ -1,13 +1,15 @@ #include #include +#include int main(int argc, char *argv[]) { - VikTrwLayer *trw = NULL; g_type_init (); - trw = vik_trw_layer_new(0); + VikLayer *vl = vik_layer_create (VIK_LAYER_TRW, NULL, NULL, 0); + VikTrwLayer *trw = VIK_TRW_LAYER (vl); a_gpx_read_file(trw, stdin); a_gpx_write_file(trw, stdout); - vik_trw_layer_free (trw); + // NB no layer_free functions directly visible anymore + // automatically called by layers_panel_finalize cleanup in full Viking program return 0; } -- 2.39.5