Ignore:
Timestamp:
Dec 16, 2007, 3:29:19 PM (12 years ago)
Author:
Sam Hocevar
Message:
  • Disable file operations in kernel mode.
  • Implement strchr() in kernel.c.
  • Check for snprintf() at configure time.
Location:
libcaca/trunk/kernel
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/kernel/kernel.c

    r1462 r2144  
    213213}
    214214
     215char *strchr(const char *s, int c)
     216{
     217    do
     218        if(*s == c)
     219            return (char *)(intptr_t)s;
     220    while(*s++);
     221
     222    return NULL;
     223}
     224
    215225/* stdarg.h functions */
    216226int vsnprintf(char *str, size_t size, const char *format, va_list ap)
  • libcaca/trunk/kernel/kernel.h

    r1462 r2144  
    8888int memcmp(const void *s1, const void *s2, size_t n);
    8989char *strdup(const char *s);
     90char *strchr(const char *s, int c);
    9091
    9192/* stdarg.h functions */
Note: See TracChangeset for help on using the changeset viewer.