< prev index next >

src/java.desktop/share/native/liblcms/cmserr.c

Print this page

        

*** 28,38 **** // file: // //--------------------------------------------------------------------------------- // // Little Color Management System ! // Copyright (c) 1998-2017 Marti Maria Saguer // // Permission is hereby granted, free of charge, to any person obtaining // a copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modify, merge, publish, distribute, sublicense, --- 28,38 ---- // file: // //--------------------------------------------------------------------------------- // // Little Color Management System ! // Copyright (c) 1998-2020 Marti Maria Saguer // // Permission is hereby granted, free of charge, to any person obtaining // a copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modify, merge, publish, distribute, sublicense,
*** 65,75 **** // that hopefully would be fully portable. // compare two strings ignoring case int CMSEXPORT cmsstrcasecmp(const char* s1, const char* s2) { ! register const unsigned char *us1 = (const unsigned char *)s1, *us2 = (const unsigned char *)s2; while (toupper(*us1) == toupper(*us2++)) if (*us1++ == '\0') return 0; --- 65,75 ---- // that hopefully would be fully portable. // compare two strings ignoring case int CMSEXPORT cmsstrcasecmp(const char* s1, const char* s2) { ! CMSREGISTER const unsigned char *us1 = (const unsigned char *)s1, *us2 = (const unsigned char *)s2; while (toupper(*us1) == toupper(*us2++)) if (*us1++ == '\0') return 0;
*** 462,472 **** // Error logging ****************************************************************** // There is no error handling at all. When a function fails, it returns proper value. // For example, all create functions does return NULL on failure. Other return FALSE // It may be interesting, for the developer, to know why the function is failing. ! // for that reason, lcms2 does offer a logging function. This function does recive // a ENGLISH string with some clues on what is going wrong. You can show this // info to the end user, or just create some sort of log. // The logging function should NOT terminate the program, as this obviously can leave // resources. It is the programmer's responsibility to check each function return code // to make sure it didn't fail. --- 462,472 ---- // Error logging ****************************************************************** // There is no error handling at all. When a function fails, it returns proper value. // For example, all create functions does return NULL on failure. Other return FALSE // It may be interesting, for the developer, to know why the function is failing. ! // for that reason, lcms2 does offer a logging function. This function does receive // a ENGLISH string with some clues on what is going wrong. You can show this // info to the end user, or just create some sort of log. // The logging function should NOT terminate the program, as this obviously can leave // resources. It is the programmer's responsibility to check each function return code // to make sure it didn't fail.
< prev index next >