X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?a=blobdiff_plain;f=src%2Fos_zlib%2Fzlib-test.c;h=fcbaabed2e400edd418a5c739fb5d5a97a5b996d;hb=6ef2f786c6c8ead94841b5f93baf9f43421f08c8;hp=6957eedcc95a15ff4c6eaf317542b9feb29c3904;hpb=914feba5d54f979cd5d7e69c349c3d01f630042a;p=ossec-hids.git diff --git a/src/os_zlib/zlib-test.c b/src/os_zlib/zlib-test.c index 6957eed..fcbaabe 100755 --- a/src/os_zlib/zlib-test.c +++ b/src/os_zlib/zlib-test.c @@ -1,15 +1,16 @@ -/* @(#) $Id: zlib-test.c,v 1.5 2009/06/24 18:53:06 dcid Exp $ */ +/* @(#) $Id: ./src/os_zlib/zlib-test.c, 2011/09/08 dcid Exp $ + */ /* Copyright (C) 2009 Trend Micro Inc. * All rights reserved. * * This program is a free software; you can redistribute it * and/or modify it under the terms of the GNU General Public - * License (version 3) as published by the FSF - Free Software + * License (version 2) as published by the FSF - Free Software * Foundation */ - + #include "shared.h" #include "os_zlib.h" @@ -20,7 +21,7 @@ /* Zlib test */ int main(int argc, char **argv) { - int ret, srcsize, dstsize = 2010; + int ret, srcsize, dstsize = 2010; char dst[2048]; char dst2[2048]; @@ -32,7 +33,7 @@ int main(int argc, char **argv) printf("%s: string\n", argv[0]); exit(1); } - + srcsize = strlen(argv[1]); if(srcsize > 2000) { @@ -40,7 +41,7 @@ int main(int argc, char **argv) exit(1); } - + if((ret = os_compress(argv[1], dst, srcsize, dstsize))) { printf("Compressed, from %d->%d\n",srcsize, ret); @@ -53,11 +54,11 @@ int main(int argc, char **argv) /* Setting new srcsize for decompression */ srcsize = ret; - + if((ret = os_uncompress(dst, dst2, srcsize, dstsize))) { - printf("Uncompressed ok. String: '%s', size %d->%d\n", - dst2, srcsize, ret); + printf("Uncompressed ok. String: '%s', size %d->%d\n", + dst2, srcsize, ret); } else {