strcasecmp(3) Library Functions Manual strcasecmp(3) NOMBRE strcasecmp, strncasecmp - comparan dos cadenas sin distinguir entre mayusculas o minusculas BIBLIOTECA Biblioteca Estandar C (libc, -lc) SINOPSIS #include int strcasecmp(const char *s1, const char *s2); int strncasecmp(const char s1[.n], const char s2[.n], size_t n); DESCRIPCION La funcion strcasecmp() compara byte a byte las dos cadenas s1 y s2, sin distinguir entre mayusculas y minusculas. Devuelve un entero menor , igual o mayor que cero si se encuentra s1, respectivamente, es menor, igual, o mayor que s2. La funcion strncasecmp() es similar, excepto que solo compara los primeros caracteres n de s1 y s2. VALOR DEVUELTO The strcasecmp() and strncasecmp() functions return an integer less than, equal to, or greater than zero if s1 is, after ignoring case, found to be less than, to match, or be greater than s2, respectively. ATRIBUTOS Para obtener una explicacion de los terminos usados en esta seccion, vease attributes(7). +--------------+--------------------+-----------------------------------------------+ |Interfaz | Atributo | Valor | +--------------+--------------------+-----------------------------------------------+ |strcasecmp(), | Seguridad del hilo | Configuracion regional de multi-hilo seguro | |strncasecmp() | | | +--------------+--------------------+-----------------------------------------------+ ESTANDARES POSIX.1-2008. HISTORIAL 4.4BSD, POSIX.1-2001. The strcasecmp() and strncasecmp() functions first appeared in 4.4BSD, where they were declared in . Thus, for reasons of historical compatibility, the glibc header file also declares these functions, if the _DEFAULT_SOURCE (or, in glibc 2.19 and earlier, _BSD_SOURCE) feature test macro is defined. El estandar POSIX.1-2008 dice de estas funciones: When the LC_CTYPE category of the locale being used is from the POSIX locale, these functions shall behave as if the strings had been converted to lowercase and then a byte comparison performed. Otherwise, the results are unspecified. VEASE TAMBIEN memcmp(3), strcmp(3), strcoll(3), string(3), strncmp(3), wcscasecmp(3), wcsncasecmp(3) TRADUCCION La traduccion al espanol de esta pagina del manual fue creada por Miguel Perez Ibars y Marcos Fouces Esta traduccion es documentacion libre; lea la GNU General Public License Version 3 o posterior con respecto a las condiciones de copyright. No existe NINGUNA RESPONSABILIDAD. Si encuentra algun error en la traduccion de esta pagina del manual, envie un correo electronico a . Paginas de manual de Linux 6.06 31 Octubre 2023 strcasecmp(3)