/illumos-gate/usr/src/lib/libc/port/locale/ |
H A D | localeimpl.c | 222 struct locdata *loc; in locdata_get_cache() local 229 loc = cache_data[category]; in locdata_get_cache() 231 if ((loc != NULL) && (strcmp(loc->l_lname, locname) == 0)) { in locdata_get_cache() 233 return (loc); in locdata_get_cache() 241 for (loc = cat_data[category]; loc != NULL; loc = loc->l_next) { in locdata_get_cache() 242 if (strcmp(locname, loc->l_lname) == 0) { in locdata_get_cache() 264 if (loc == NULL) { in locdata_get_cache() 266 loc = (*loaders[category])(locname); in locdata_get_cache() 268 if (loc != NULL) in locdata_get_cache() 269 (void) strlcpy(loc->l_lname, locname, in locdata_get_cache() [all …]
|
H A D | setlocale.c | 70 locale_t loc; in setlocale() local 84 loc = newlocale(mask, locname, NULL); in setlocale() 85 if (loc == NULL) { in setlocale() 100 if (strcmp(srch->locname, loc->locname) == 0) { in setlocale() 107 loc->next = setlocale_list; in setlocale() 108 loc->on_list = 1; in setlocale() 109 setlocale_list = loc; in setlocale() 112 freelocale(loc); in setlocale() 113 loc = srch; in setlocale() 115 ___global_locale = loc; in setlocale() [all …]
|
H A D | fnmatch.c | 78 locale_t loc = uselocale(NULL); in fnmatch() local 82 loc)); in fnmatch() 87 int flags, mbstate_t patmbs, mbstate_t strmbs, locale_t loc) in fnmatch1() argument 98 pclen = mbrtowc_l(&pc, pattern, MB_LEN_MAX, &patmbs, loc); in fnmatch1() 102 sclen = mbrtowc_l(&sc, string, MB_LEN_MAX, &strmbs, loc); in fnmatch1() 171 &patmbs, loc)) { in fnmatch1() 185 &patmbs, loc); in fnmatch1() 198 (towlower_l(pc, loc) == towlower_l(sc, loc))) in fnmatch1() 211 &bt_strmbs, loc); in fnmatch1() 235 mbstate_t *patmbs, locale_t loc) in rangematch() argument [all …]
|
H A D | wcscasecmp.c | 45 wcscasecmp_l(const wchar_t *s1, const wchar_t *s2, locale_t loc) in wcscasecmp_l() argument 50 while (towlower_l(*s1, loc) == towlower_l(*s2, loc)) { in wcscasecmp_l() 56 return (towlower_l(*s1, loc) - towlower_l(*s2, loc)); in wcscasecmp_l() 66 wcsncasecmp_l(const wchar_t *s1, const wchar_t *s2, size_t n, locale_t loc) in wcsncasecmp_l() argument 71 while ((towlower_l(*s1, loc) == towlower_l(*s2, loc)) && --n) { in wcsncasecmp_l() 77 return (towlower_l(*s1, loc) - towlower_l(*s2, loc)); in wcsncasecmp_l()
|
H A D | localeconv.c | 59 locale_t loc; in localeconv() local 63 loc = uselocale(NULL); in localeconv() 64 lconv = &loc->lconv; in localeconv() 66 if (loc->loaded[LC_MONETARY] == 0) { in localeconv() 67 mptr = loc->locdata[LC_MONETARY]->l_data[0]; in localeconv() 93 loc->loaded[LC_MONETARY] = 1; in localeconv() 96 if (loc->loaded[LC_NUMERIC] == 0) { in localeconv() 97 nptr = loc->locdata[LC_NUMERIC]->l_data[0]; in localeconv() 104 loc->loaded[LC_NUMERIC] = 1; in localeconv()
|
H A D | towlower.c | 48 change_case_ext(locale_t loc, wint_t c, int lower) in change_case_ext() argument 58 rl = loc->runelocale; in change_case_ext() 76 towlower_l(wint_t wc, locale_t loc) in towlower_l() argument 80 change_case_ext(loc, wc, 1) : in towlower_l() 81 loc->runelocale->__maplower[wc]); in towlower_l() 95 towupper_l(wint_t wc, locale_t loc) in towupper_l() argument 99 change_case_ext(loc, wc, 0) : in towupper_l() 100 loc->runelocale->__mapupper[wc]); in towupper_l()
|
H A D | fgetwc.c | 46 _fgetwc_unlocked_l(FILE *fp, locale_t loc) in _fgetwc_unlocked_l() argument 57 lct = loc->ctype; in _fgetwc_unlocked_l() 115 locale_t loc = uselocale(NULL); in fgetwc() local 118 r = _fgetwc_unlocked_l(fp, loc); in fgetwc() 134 locale_t loc = uselocale(NULL); in __fgetwc_xpg5() local 139 r = _fgetwc_unlocked_l(fp, loc); in __fgetwc_xpg5() 147 fgetwc_l(FILE *fp, locale_t loc) in fgetwc_l() argument 154 r = _fgetwc_unlocked_l(fp, loc); in fgetwc_l()
|
H A D | strftime.c | 92 locale_t loc) in strftime_l() argument 98 p = _fmt(loc, ((format == NULL) ? "%c" : format), t, s, e); in strftime_l() 113 _fmt(locale_t loc, const char *format, const struct tm *t, char *pt, in _fmt() argument 117 const struct lc_time *tptr = loc->time; in _fmt() 168 pt = _fmt(loc, tptr->c_fmt, t, pt, ptlim); in _fmt() 171 pt = _fmt(loc, "%m/%d/%y", t, pt, ptlim); in _fmt() 201 pt = _fmt(loc, "%Y-%m-%d", t, pt, ptlim); in _fmt() 261 pt = _fmt(loc, "%H:%M", t, pt, ptlim); in _fmt() 264 pt = _fmt(loc, tptr->ampm_fmt, t, pt, ptlim); in _fmt() 283 pt = _fmt(loc, "%H:%M:%S", t, pt, ptlim); in _fmt() [all …]
|
/illumos-gate/usr/src/uts/common/io/xge/hal/include/ |
H A D | xgehal-types.h | 34 #define BIT(loc) (0x8000000000000000ULL >> (loc)) argument 39 #define vBIT(val, loc, sz) (((u64)(val)) << (64-(loc)-(sz))) argument 40 #define vBIT32(val, loc, sz) (((u32)(val)) << (32-(loc)-(sz))) argument 45 #define bVAL1(bits, loc) ((((u64)bits) >> (64-(loc+1))) & 0x1) argument 46 #define bVAL2(bits, loc) ((((u64)bits) >> (64-(loc+2))) & 0x3) argument 47 #define bVAL3(bits, loc) ((((u64)bits) >> (64-(loc+3))) & 0x7) argument 48 #define bVAL4(bits, loc) ((((u64)bits) >> (64-(loc+4))) & 0xF) argument 49 #define bVAL5(bits, loc) ((((u64)bits) >> (64-(loc+5))) & 0x1F) argument 50 #define bVAL6(bits, loc) ((((u64)bits) >> (64-(loc+6))) & 0x3F) argument 51 #define bVAL7(bits, loc) ((((u64)bits) >> (64-(loc+7))) & 0x7F) argument [all …]
|
/illumos-gate/usr/src/cmd/svc/milestone/ |
H A D | net-loc | 62 LEGACY_LOC_PATH=/etc/nwam/loc/Legacy 63 USER_LOC_PATH=/etc/nwam/loc/User 178 loc=$1 184 DNS_CONFIGSRC=`nwam_get_loc_list_prop $loc dns-nameservice-configsrc` 186 echo "missing 'dns-nameservice-configsrc' property for '$loc'" 193 DNS_SERVERS=`nwam_get_loc_list_prop $loc \ 196 echo "DNS nameserver not set for '$loc'" 199 DNS_DOMAIN=`nwam_get_loc_prop $loc \ 201 DNS_SEARCH=`nwam_get_loc_list_prop $loc \ 250 loc=$1 [all …]
|
/illumos-gate/usr/src/test/libc-tests/tests/newlocale/ |
H A D | newlocale_test.c | 62 locale_t cloc, loc; in testlocale_thr_one() local 70 loc = newlocale(LC_ALL_MASK, l->locale, NULL); in testlocale_thr_one() 71 if (loc == NULL) { in testlocale_thr_one() 74 day = nl_langinfo_l(DAY_1, loc); in testlocale_thr_one() 96 (void) uselocale(loc); in testlocale_thr_one() 114 if (uselocale(cloc) != loc) { in testlocale_thr_one() 117 freelocale(loc); in testlocale_thr_one() 135 locale_t loc, bad; in test_newlocale_negative() local 141 loc = newlocale(LC_ALL_MASK, "de_DE.UTF-8", NULL); in test_newlocale_negative() 142 if (loc == NULL) { in test_newlocale_negative() [all …]
|
/illumos-gate/usr/src/lib/libc/port/gen/ |
H A D | tsdalloc.c | 46 tsdent_t *loc = ptr; in _free_tsdbuf() local 51 if (loc != NULL) { in _free_tsdbuf() 53 if ((p = loc[i].buf) != NULL) { in _free_tsdbuf() 54 destructor = loc[i].destructor; in _free_tsdbuf() 57 lfree(p, loc[i].size); in _free_tsdbuf() 60 lfree(loc, _T_NUM_ENTRIES * sizeof (tsdent_t)); in _free_tsdbuf() 68 tsdent_t *loc; in tsdalloc() local 82 if ((loc = pthread_getspecific(key)) != NULL) { in tsdalloc() 83 if ((p = loc[n].buf) != NULL) in tsdalloc() 87 loc = lmalloc(_T_NUM_ENTRIES * sizeof (tsdent_t)); in tsdalloc() [all …]
|
H A D | seekdir.c | 51 seekdir(DIR *dirp, long loc) in seekdir() argument 62 if (off != loc) { in seekdir() 64 (void) lseek(dirp->dd_fd, loc, SEEK_SET); in seekdir() 71 ((dirent_t *)(uintptr_t)&dirp->dd_buf[0])->d_off = loc; in seekdir() 84 seekdir64(DIR *dirp, off64_t loc) in seekdir64() argument 105 if (off != loc) { in seekdir64() 107 (void) lseek64(dirp->dd_fd, loc, SEEK_SET); in seekdir64() 114 ((dirent64_t *)(uintptr_t)&dirp->dd_buf[0])->d_off = loc; in seekdir64() 120 seekdir(DIR *dirp, long loc) in seekdir() argument 122 seekdir64(dirp, (off64_t)(uint32_t)loc); in seekdir()
|
H A D | gettxt.c | 71 char *loc; member 92 locale_t loc; in gettxt() local 123 loc = uselocale(NULL); in gettxt() 124 curloc = current_locale(loc, LC_MESSAGES); in gettxt() 131 if (strcmp(curloc, dbc->loc) == 0) { in gettxt() 152 if ((dbc->loc = lmalloc(strlen(curloc) + 1)) == NULL) { in gettxt() 158 (void) strcpy(dbc->loc, curloc); in gettxt() 169 _DFLT_LOC_PATH "%s" MESSAGES "%s", dbc->loc, msgfile) >= in gettxt() 183 if (strcmp(dbc->loc, "C") == 0) { in gettxt()
|
/illumos-gate/usr/src/lib/libnisdb/ |
H A D | db_index_entry_c.c | 47 db_index_entry *loc; in xdr_db_index_entry() local 87 loc = ep->next; in xdr_db_index_entry() 92 if (loc == NULL) { in xdr_db_index_entry() 93 ep->next = loc = (db_index_entry *) in xdr_db_index_entry() 95 if (loc == NULL) { in xdr_db_index_entry() 100 memset(loc, 0, sizeof (db_index_entry)); in xdr_db_index_entry() 108 freeptr = loc; in xdr_db_index_entry() 112 if (loc == NULL) in xdr_db_index_entry() 114 ep = loc; in xdr_db_index_entry() 142 db_free_entry *loc; in xdr_db_free_entry() local [all …]
|
H A D | db_table.cc | 889 db_table::cacheValid(entryp loc) { in cacheValid() argument 897 if (loc < 0 || loc >= table_size || tab == 0 || tab[loc] == 0) in cacheValid() 899 else if (mapping.expire == 0 || mapping.expire[loc] >= now.tv_sec) in cacheValid() 914 db_table::dupEntry(entry_object *obj, entryp loc) { in dupEntry() argument 915 if (obj == 0 || loc < 0 || loc >= table_size || tab == 0 || in dupEntry() 916 tab[loc] == 0) in dupEntry() 919 if (sameEntry(obj, tab[loc])) { in dupEntry() 920 setEntryExp(loc, tab[loc], 0); in dupEntry() 923 enumTouch(loc); in dupEntry() 1032 db_table::enumTouch(entryp loc) { in enumTouch() argument [all …]
|
/illumos-gate/usr/src/common/zfs/ |
H A D | zfs_namecheck.c | 74 const char *loc = path; in get_dataset_depth() local 81 for (int i = 0; loc[i] != '\0' && in get_dataset_depth() 82 loc[i] != '@' && in get_dataset_depth() 83 loc[i] != '#'; i++) { in get_dataset_depth() 84 if (loc[i] == '/') in get_dataset_depth() 102 const char *loc; in zfs_component_namecheck() local 116 for (loc = path; *loc; loc++) { in zfs_component_namecheck() 117 if (!valid_char(*loc)) { in zfs_component_namecheck() 120 *what = *loc; in zfs_component_namecheck() 227 for (const char *loc = start; loc != end; loc++) { in entity_namecheck() local [all …]
|
/illumos-gate/usr/src/test/libc-tests/tests/priv_gettext/ |
H A D | priv_gettext.c | 55 locale_t loc; in main() local 64 loc = newlocale(LC_MESSAGES_MASK, "zz_AA.UTF-8", NULL); in main() 65 assert(loc != NULL); in main() 68 (void) uselocale(loc); in main() 73 freelocale(loc); in main() 76 loc = newlocale(LC_MESSAGES_MASK, "C", NULL); in main() 77 assert(loc != NULL); in main() 80 (void) uselocale(loc); in main() 85 freelocale(loc); in main()
|
/illumos-gate/usr/src/test/libc-tests/tests/ |
H A D | strerror.c | 59 strerror_l_verify(locale_t loc, const char *exp) in strerror_l_verify() argument 63 r = strerror_l(terr, loc); in strerror_l_verify() 91 locale_t loc; in main() local 111 loc = newlocale(LC_MESSAGES_MASK, "zz_AA.UTF-8", NULL); in main() 112 VERIFY(loc != NULL); in main() 116 strerror_l_verify(loc, trans); in main() 120 (void) uselocale(loc); in main() 123 strerror_l_verify(loc, trans); in main() 130 strerror_l_verify(loc, trans); in main() 145 freelocale(loc); in main()
|
/illumos-gate/usr/src/test/libc-tests/tests/catopen/ |
H A D | catopen.c | 51 locale_t loc; in main() local 63 loc = newlocale(LC_MESSAGES_MASK, "zz_AA.UTF-8", NULL); in main() 64 assert(loc != NULL); in main() 67 (void) uselocale(loc); in main() 72 freelocale(loc); in main() 77 loc = newlocale(LC_MESSAGES_MASK, "C", NULL); in main() 78 assert(loc != NULL); in main() 81 (void) uselocale(loc); in main()
|
/illumos-gate/usr/src/lib/fm/topo/libtopo/common/ |
H A D | svc.c | 520 char *str, *loc, val; in svc_fmri_str2nvl() local 535 if ((loc = strpbrk(str, "@/")) == NULL) in svc_fmri_str2nvl() 538 if (*loc == '@') { in svc_fmri_str2nvl() 540 *loc = '\0'; in svc_fmri_str2nvl() 542 *loc = '@'; in svc_fmri_str2nvl() 547 *loc = '@'; in svc_fmri_str2nvl() 551 *loc = '@'; in svc_fmri_str2nvl() 552 str = loc + 1; in svc_fmri_str2nvl() 553 if ((loc = strchr(str, '/')) == NULL) in svc_fmri_str2nvl() 557 if (loc != str) { in svc_fmri_str2nvl() [all …]
|
/illumos-gate/usr/src/lib/libnsl/rpc/ |
H A D | xdr_refer.c | 66 caddr_t loc = *pp; in xdr_reference() local 75 if (loc == NULL) in xdr_reference() 80 *pp = loc = malloc(size); in xdr_reference() 81 if (loc == NULL) { in xdr_reference() 85 (void) memset(loc, 0, (int)size); in xdr_reference() 89 stat = (*proc)(xdrs, loc, LASTUNSIGNED); in xdr_reference() 92 free(loc); in xdr_reference()
|
/illumos-gate/usr/src/contrib/ast/src/cmd/msgcc/ |
H A D | msgget.c | 54 char* loc; in main() local 79 if (error_info.errors || !(loc = *argv++) || !(cmd = *argv++) || !(s = *argv++)) in main() 89 if (streq(loc, "-")) in main() 90 loc = 0; in main() 93 …if (!mcfind(loc, cmd, LC_MESSAGES, 0, path, sizeof(path)) && (!cat || !mcfind(loc, cat, LC_MESSAGE… in main() 106 s = errorx(loc, cmd, cat, msg); in main()
|
/illumos-gate/usr/src/uts/common/rpc/ |
H A D | xdr_refer.c | 68 caddr_t loc = *pp; in xdr_reference() local 71 if (loc == NULL) { in xdr_reference() 77 *pp = loc = (caddr_t)mem_alloc(size); in xdr_reference() 78 bzero(loc, size); in xdr_reference() 86 stat = (*proc)(xdrs, loc, LASTUNSIGNED); in xdr_reference() 89 mem_free(loc, size); in xdr_reference()
|
/illumos-gate/usr/src/cmd/svc/configd/ |
H A D | object.c | 342 check_string(uintptr_t loc, uint32_t len, uint32_t sz) in check_string() argument 344 const char *ptr = (const char *)loc; in check_string() 359 uintptr_t loc; in tx_check_and_setup() local 363 loc = (uintptr_t)cmds_arg; in tx_check_and_setup() 368 cmds = (struct rep_protocol_transaction_cmd *)loc; in tx_check_and_setup() 373 loc += REP_PROTOCOL_TRANSACTION_CMD_MIN_SIZE; in tx_check_and_setup() 377 if (len <= 1 || !check_string(loc, len, sz)) { in tx_check_and_setup() 380 cur->tx_prop = (const char *)loc; in tx_check_and_setup() 383 loc += len; in tx_check_and_setup() 387 cur->tx_values = (uint32_t *)loc; in tx_check_and_setup() [all …]
|