From d9beaa185dc607db40eac468e871fb507285e41c Mon Sep 17 00:00:00 2001 From: rikky Date: Wed, 31 Aug 2011 21:44:39 +0000 Subject: [PATCH] Fix:core:Remove some "write but never read" variables git-svn-id: https://navit.svn.sourceforge.net/svnroot/navit/trunk@4740 ffa7fe5e-494d-0410-b361-a75ebd5db220 --- navit/navit/map/binfile/binfile.c | 3 +-- navit/navit/route.c | 6 ++---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/navit/navit/map/binfile/binfile.c b/navit/navit/map/binfile/binfile.c index 2b52dfc..e243d50 100644 --- a/navit/navit/map/binfile/binfile.c +++ b/navit/navit/map/binfile/binfile.c @@ -705,7 +705,7 @@ binfile_attr_set(void *priv_data, struct attr *attr, enum change_mode mode) { struct map_rect_priv *mr=priv_data; struct tile *t=mr->t,*tn,new; - int extend,offset,delta,move_len; + int offset,delta,move_len; int write_offset,move_offset,naoffset,coffset,oattr_len; int nattr_size,nattr_len,pad; int *data; @@ -744,7 +744,6 @@ binfile_attr_set(void *priv_data, struct attr *attr, enum change_mode mode) nattr_size=0; nattr_len=0; pad=0; - extend=0; break; case change_mode_modify: case change_mode_prepend: diff --git a/navit/navit/route.c b/navit/navit/route.c index 5579ec0..fab9e7d 100644 --- a/navit/navit/route.c +++ b/navit/navit/route.c @@ -2033,7 +2033,7 @@ route_graph_flood(struct route_graph *this, struct route_info *dst, struct vehic { struct route_graph_point *p_min; struct route_graph_segment *s=NULL; - int min,new,old,val; + int min,new,val; struct fibheap *heap; /* This heap will hold all points with "temporarily" calculated costs */ heap = fh_makekeyheap(); @@ -2098,7 +2098,6 @@ route_graph_flood(struct route_graph *this, struct route_info *dst, struct vehic if (debug_route) printf("end %d len %d vs %d (0x%x,0x%x)\n",new,val,s->start->value,s->start->c.x, s->start->c.y); if (new < s->start->value) { - old=s->start->value; s->start->value=new; s->start->seg=s; if (! s->start->el) { @@ -2224,7 +2223,7 @@ route_get_coord_dist(struct route *this_, int dist) static struct route_path * route_path_new(struct route_graph *this, struct route_path *oldpath, struct route_info *pos, struct route_info *dst, struct vehicleprofile *profile) { - struct route_graph_segment *first,*s=NULL,*s1=NULL,*s2=NULL; + struct route_graph_segment *s=NULL,*s1=NULL,*s2=NULL; struct route_graph_point *start; struct route_info *posinfo, *dstinfo; int segs=0; @@ -2282,7 +2281,6 @@ route_path_new(struct route_graph *this, struct route_path *oldpath, struct rout ret->path_hash=item_hash_new(); dstinfo=NULL; posinfo=pos; - first=s; while (s && !dstinfo) { /* following start->seg, which indicates the least costly way to reach our destination */ segs++; #if 0 -- 2.7.4