-/**************************************************************************
+/*************************************************************************
*
-* Copyright (C) 2001-2005, International Business Machines
+* © 2016 and later: Unicode, Inc. and others.
+* License & terms of use: http://www.unicode.org/copyright.html#License
+*
+**************************************************************************
+**************************************************************************
+*
+* Copyright (C) 2001-2006, International Business Machines
* Corporation and others. All Rights Reserved.
*
-***************************************************************************
+**************************************************************************
*
* ufortune - An ICU resources sample program
*
exit(-1);
}
- i = time(NULL) % numFortunes; /* Use time to pick a somewhat-random fortune. */
+ i = (int)time(NULL) % numFortunes; /* Use time to pick a somewhat-random fortune. */
resString = ures_getStringByIndex(fortunes_r, i, &len, &err);
if (U_FAILURE(err)) {
fprintf(stderr, "%s: ures_getStringByIndex(%d) failed, %s\n", programName, i, u_errorName(err));