]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/zstream.cpp
deal with Cocoa as we do with Carbon, see #15008
[wxWidgets.git] / src / common / zstream.cpp
index 031dbb29e8f08fc1b269a22f7eee8bd3b0a36ff0..ce63c07dc9135f28a41426057763ed971b5d1e36 100644 (file)
@@ -47,10 +47,18 @@ enum {
 
 wxVersionInfo wxGetZlibVersionInfo()
 {
-    return wxVersionInfo("zlib",
-                         ZLIB_VERNUM >> 12,
-                         (ZLIB_VERNUM >> 8) & 0x0F,
-                         (ZLIB_VERNUM & 0xFF) / 0x10);
+    int major,
+        minor,
+        build;
+
+    if ( sscanf(zlibVersion(), "%d.%d.%d", &major, &minor, &build) != 3 )
+    {
+        major =
+        minor =
+        build = 0;
+    }
+
+    return wxVersionInfo("zlib", major, minor, build);
 }
 
 /////////////////////////////////////////////////////////////////////////////