X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=test%2Ftstnmem.c;h=80a2e56d5a005c3de28903e0dacd45a37abc344f;hp=5f310cbc50e1ae78e0b11f447c52f634a6b66977;hb=dc0ea3eaeb38d04f10118bfe62cd8e6c80033ce6;hpb=2788a4851b551e1a3efb320a2878b809f2d8a9d7 diff --git a/test/tstnmem.c b/test/tstnmem.c index 5f310cb..80a2e56 100644 --- a/test/tstnmem.c +++ b/test/tstnmem.c @@ -1,5 +1,5 @@ /* This file is part of the YAZ toolkit. - * Copyright (C) 1995-2009 Index Data + * Copyright (C) 1995-2010 Index Data * See the file LICENSE for details. */ @@ -28,13 +28,13 @@ void tst(void) { cp = (char *) nmem_malloc(n, j); YAZ_CHECK(cp); - if (sizeof(long) >= j) + if ((int) sizeof(long) >= j) *(long*) cp = 123L; #if HAVE_LONG_LONG - if (sizeof(long long) >= j) + if ((int) sizeof(long long) >= j) *(long long*) cp = 123L; #endif - if (sizeof(double) >= j) + if ((int) sizeof(double) >= j) *(double*) cp = 12.2; } @@ -55,6 +55,7 @@ int main (int argc, char **argv) /* * Local variables: * c-basic-offset: 4 + * c-file-style: "Stroustrup" * indent-tabs-mode: nil * End: * vim: shiftwidth=4 tabstop=8 expandtab