What can I say, I've stumbled about something that is puzzling me.
I'm pretty new to Qt and I'm experimenting with the functions Qt has. In one of those experiments I wanted to load a zip file from the hard disk. A zip file is pretty useless if it's still zipped. Therefore I wanted to unzip the file. I knew Qt has these nice QCompress() and QUncompress() functions, yet I wanted to achieve my objective with zlib.
Using zlib in my Qt project was easy, the project compiled and run perfectly. Then I stumbled about something: When I printed out the version number of zlib, the result was 1.2.3. Wasn't I using 1.2.5? Indeed, I did!
My first thought was that there might be older version of the DLL in my system files, but there wasn't. Yet the project ran. Even without the zlib1.dll in the executive path. I realised that the project compiled in release mode to. And even linked, but I haven't set the linker settings for zlib in release mode. So I created another small C++ project where I used zlib and printed the version number. Nothing else. It said 1.2.5. It didn't run without zlib1.dll in the executive path or didn't link without the reference to zlib.dll. ;)
I can't remove the zlib header file from my project, otherwise the project won't compile. Now, how can this be? Is there a wrapper around zlib in Qt, and are the functions available in a global scope? Or how comes that everything works fine with just the zlib header file in my project?
Also, has someone an idea how I can achieve the goal of opening password protected zip files? I want to store sensitive files in a password protected zip file, so users can't change them without the programms supervision. Any libs, best practices or hints to achieve that? It hasn't to be a zip file, it also can be some kind of encrypted file.
Thanks in advance!