From 50e79d60ce148f86bc93cc3248c3f6f0f81b3c3e Mon Sep 17 00:00:00 2001 From: Andrew MacIsaac Date: Wed, 29 Dec 2010 12:15:48 -0800 Subject: Compilation Warnings on OS X 10.5 I received a number of "-Wshadow" related warnings (treated as errors) while trying to build on OS X Leopard. In addition, there were two miscellaneous other warnings in the flash drivers. Attached are two patches which correct these issues and the commit messages to accompany them. My system has the following configuration (taken from uname -a): Darwin 9.8.0 Darwin Kernel Version 9.8.0: Wed Jul 15 16:55:01 PDT 2009; root:xnu-1228.15.4~1/RELEASE_I386 i386 === Werror_patch.txt Commit Message === compilation: fixes for -Wshadow warnings on OS X These changes fix -Wshadow compilation warnings on OS X 10.5.8 Compiled with the following configure command: ../configure --prefix=/usr/local --enable-maintainer-mode --enable-jlink --enable-ft2232_libftdi === flash_patch.txt Commit Message === compilation: fixes for flash driver warnings on OS X These changes fix two compilation warnings on OS X 10.5.8: ../../../../src/flash/nor/at91sam3.c:2767: warning: redundant redeclaration of 'at91sam3_flash' ../../../../src/flash/nor/at91sam3.c:101: warning: previous declaration of 'at91sam3_flash' was here and ../../../../src/flash/nor/stmsmi.c:205: warning: format not a string literal and no format arguments Compiled with the following configure command: ../configure --prefix=/usr/local --enable-maintainer-mode --enable-jlink --enable-ft2232_libftdi === Andrew --- src/helper/fileio.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/helper') diff --git a/src/helper/fileio.h b/src/helper/fileio.h index fa499ab7..f37dbd14 100644 --- a/src/helper/fileio.h +++ b/src/helper/fileio.h @@ -53,7 +53,7 @@ struct fileio }; int fileio_open(struct fileio *fileio, - const char *url, enum fileio_access access, enum fileio_type type); + const char *url, enum fileio_access access_type, enum fileio_type type); int fileio_close(struct fileio *fileio); int fileio_seek(struct fileio *fileio, size_t position); -- cgit v1.2.3