summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgauthier60 <gauthier60@ffa7fe5e-494d-0410-b361-a75ebd5db220>2010-04-11 17:17:33 +0000
committergauthier60 <gauthier60@ffa7fe5e-494d-0410-b361-a75ebd5db220>2010-04-11 17:17:33 +0000
commit0bcafc04824d71e72da71749e1536bc0b1cd82d4 (patch)
treea20f0b8bd3535067d8fb8c74285598b9e5145f55
parent905328115c5086a03620ce9fe7c215e2fa588e8f (diff)
downloadnavit-svn-0bcafc04824d71e72da71749e1536bc0b1cd82d4.tar.gz
With Microsoft printf library the format for long long type is %I64d and not %Ld
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit/navit@3152 ffa7fe5e-494d-0410-b361-a75ebd5db220
-rw-r--r--maptool/buffer.c2
-rw-r--r--maptool/coastline.c2
-rw-r--r--maptool/geom.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/maptool/buffer.c b/maptool/buffer.c
index cb92494b..4772627c 100644
--- a/maptool/buffer.c
+++ b/maptool/buffer.c
@@ -33,7 +33,7 @@ load_buffer(char *filename, struct buffer *b, long long offset, long long size)
ret=1;
}
b->size=b->malloced=size;
- fprintf(stderr,"reading %Ld bytes from %s at %Ld\n", b->size, filename, offset);
+ fprintf(stderr,"reading "LONGLONG_FMT" bytes from %s at "LONGLONG_FMT"\n", b->size, filename, offset);
fseek(f, offset, SEEK_SET);
b->base=malloc(b->size);
dbg_assert(b->base != NULL);
diff --git a/maptool/coastline.c b/maptool/coastline.c
index 7369ad7b..4c85dfd8 100644
--- a/maptool/coastline.c
+++ b/maptool/coastline.c
@@ -175,7 +175,7 @@ tile_collector_process_tile(char *tile, int *tile_data, struct coastline_tile_da
while (sort_segments) {
struct geom_poly_segment *seg=sort_segments->data;
struct item_bin *ib=(struct item_bin *)buffer;
- char *text=g_strdup_printf("segment %d type %d %p %s area %Ld",count++,seg->type,sort_segments,coord_is_equal(*seg->first, *seg->last) ? "closed":"open",geom_poly_area(seg->first,seg->last-seg->first+1));
+ char *text=g_strdup_printf("segment %d type %d %p %s area "LONGLONG_FMT,count++,seg->type,sort_segments,coord_is_equal(*seg->first, *seg->last) ? "closed":"open",geom_poly_area(seg->first,seg->last-seg->first+1));
item_bin_init(ib, type_rg_segment);
item_bin_add_coord(ib, seg->first, seg->last-seg->first+1);
item_bin_add_attr_string(ib, attr_debug, text);
diff --git a/maptool/geom.c b/maptool/geom.c
index 6c6e20c2..1632ad9d 100644
--- a/maptool/geom.c
+++ b/maptool/geom.c
@@ -40,11 +40,11 @@ geom_poly_area(struct coord *c, int count)
if (++j == count)
j=0;
#if 0
- fprintf(stderr,"(%d+%d)*(%d-%d)=%d*%d=%Ld\n",c[i].x,c[j].x,c[i].y,c[j].y,c[i].x+c[j].x,c[i].y-c[j].y,(long long)(c[i].x+c[j].x)*(c[i].y-c[j].y));
+ fprintf(stderr,"(%d+%d)*(%d-%d)=%d*%d="LONGLONG_FMT"\n",c[i].x,c[j].x,c[i].y,c[j].y,c[i].x+c[j].x,c[i].y-c[j].y,(long long)(c[i].x+c[j].x)*(c[i].y-c[j].y));
#endif
area+=(long long)(c[i].x+c[j].x)*(c[i].y-c[j].y);
#if 0
- fprintf(stderr,"area=%Ld\n",area);
+ fprintf(stderr,"area="LONGLONG_FMT"\n",area);
#endif
}
return area/2;