Avoid compiler warning in dlls/gphoto2.ds/gphoto2_main.c

Gerald Pfeifer gerald at pfeifer.com
Thu May 28 14:25:35 CDT 2009


This patch addresses the following compiler warning when we are
compiling without gphoto2 support:

  gphoto2_main.c:40: warning: 'GPHOTO2_StrDup' defined but not used

Gerald

ChangeLog:
Only provide GPHOTO2_StrDup() when we have HAVE_GPHOTO2.

diff --git a/dlls/gphoto2.ds/gphoto2_main.c b/dlls/gphoto2.ds/gphoto2_main.c
index ab4f392..5d80d4c 100644
--- a/dlls/gphoto2.ds/gphoto2_main.c
+++ b/dlls/gphoto2.ds/gphoto2_main.c
@@ -37,12 +37,14 @@
 WINE_DEFAULT_DEBUG_CHANNEL(twain);
 
 
+#ifdef HAVE_GPHOTO2
 static char* GPHOTO2_StrDup(const char* str)
 {
     char* dst = HeapAlloc(GetProcessHeap(), 0, strlen(str)+1);
     strcpy(dst, str);
     return dst;
 }
+#endif
 
 static void
 load_filesystem(const char *folder) {



More information about the wine-patches mailing list