- got tired of str[n]casecmp not declared warnings

- added BLI_str[n]casecmp, use instead of regular versions
 - rewrote BLI_str[n]casecmp to not be stupid
This commit is contained in:
2005-04-02 15:36:57 +00:00
parent bdb86d7c67
commit 24c9f65056
19 changed files with 210 additions and 202 deletions

View File

@@ -30,13 +30,9 @@
* ***** END GPL/BL DUAL LICENSE BLOCK *****
*/
#if defined(__WIN32__) || defined(WIN32) || defined(_WIN32)
#include <string.h>
#else
#include <strings.h> /*for strcasecmp */
#endif
#include <DNA_text_types.h>
#include <MEM_guardedalloc.h>
#include <BLI_blenlib.h>
#include "gen_utils.h"
#include "constant.h"
@@ -234,7 +230,7 @@ int EXPP_map_case_getIntVal( const EXPP_map_pair * map, const char *sval,
int *ival )
{
while( map->sval ) {
if( !strcasecmp( sval, map->sval ) ) {
if( !BLI_strcasecmp( sval, map->sval ) ) {
*ival = map->ival;
return 1;
}

View File

@@ -928,7 +928,7 @@ PyObject *RenderData_Play( BPy_RenderData * self )
BLI_convertstringcode( file, (char *) self->scene,
self->renderContext->cfra );
RE_make_existing_file( file );
if( strcasecmp( file + strlen( file ) - 4, ".mov" ) ) {
if( BLI_strcasecmp( file + strlen( file ) - 4, ".mov" ) ) {
sprintf( txt, "%04d_%04d.mov",
( self->renderContext->sfra ),
( self->renderContext->efra ) );
@@ -942,7 +942,7 @@ PyObject *RenderData_Play( BPy_RenderData * self )
BLI_convertstringcode( file, G.sce,
self->renderContext->cfra );
RE_make_existing_file( file );
if( strcasecmp( file + strlen( file ) - 4, ".avi" ) ) {
if( BLI_strcasecmp( file + strlen( file ) - 4, ".avi" ) ) {
sprintf( txt, "%04d_%04d.avi",
( self->renderContext->sfra ),
( self->renderContext->efra ) );