Changeset 980311e in mainline


Ignore:
Timestamp:
2011-08-24T21:32:32Z (13 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
81e9cb3
Parents:
a5454cf
Message:

Remove wstr_chr().

Location:
uspace
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/str.c

    ra5454cf r980311e  
    873873       
    874874        return (char *) res;
    875 }
    876 
    877 /** Find first occurence of character in wide string.
    878  *
    879  * @param wstr String to search.
    880  * @param ch  Character to look for.
    881  *
    882  * @return Pointer to character in @a wstr or NULL if not found.
    883  */
    884 wchar_t *wstr_chr(const wchar_t *wstr, wchar_t ch)
    885 {
    886         while (*wstr && *wstr != ch)
    887                 wstr++;
    888         if (*wstr)
    889                 return (wchar_t *) wstr;
    890         else
    891                 return NULL;
    892875}
    893876
  • uspace/lib/c/include/str.h

    ra5454cf r980311e  
    9090extern char *str_chr(const char *str, wchar_t ch);
    9191extern char *str_rchr(const char *str, wchar_t ch);
    92 extern wchar_t *wstr_chr(const wchar_t *wstr, wchar_t ch);
    9392
    9493extern bool wstr_linsert(wchar_t *str, wchar_t ch, size_t pos, size_t max_pos);
  • uspace/srv/fs/fat/fat_dentry.c

    ra5454cf r980311e  
    356356       
    357357        while ((ch = str_decode(name, &offset, STR_NO_LIMIT)) != 0) {
    358                 if (wstr_chr(FAT_STOP_CHARS, ch) != NULL) {
     358                if (str_chr(FAT_STOP_CHARS, ch) != NULL) {
    359359                        result = false;
    360360                        break;
  • uspace/srv/fs/fat/fat_dentry.h

    ra5454cf r980311e  
    3939
    4040#define IS_D_CHAR(ch) (isalnum(ch) || ch == '_')
    41 #define FAT_STOP_CHARS L"*?/\\\n\t|'"
     41#define FAT_STOP_CHARS "*?/\\\n\t|'"
    4242
    4343#define FAT_NAME_LEN            8
Note: See TracChangeset for help on using the changeset viewer.