Home
last modified time | relevance | path

Searched refs:mbs (Results 1 – 25 of 56) sorted by relevance

123

/titanic_41/usr/src/test/libc-tests/tests/wcsrtombs/
H A Dwcsrtombs_test.c44 char mbs[32]; member
97 for (int i = 0; test[i].mbs[0] != 0; i++) { in test_wcsrtombs_1()
98 char mbs[32]; in test_wcsrtombs_1() local
103 (void) memset(mbs, 0, sizeof (mbs)); in test_wcsrtombs_1()
104 cnt = wcsrtombs(mbs, &wcs, sizeof (mbs), &ms); in test_wcsrtombs_1()
105 if (cnt != strlen(test[i].mbs)) { in test_wcsrtombs_1()
107 cnt, strlen(test[i].mbs)); in test_wcsrtombs_1()
109 if (strcmp(mbs, test[i].mbs) != 0) { in test_wcsrtombs_1()
111 mbs, test[i].mbs); in test_wcsrtombs_1()
114 test_debugf(t, "mbs is %s", mbs); in test_wcsrtombs_1()
[all …]
/titanic_41/usr/src/lib/libxcurses/src/libc/xcurses/
H A Dinsnstr.c47 (insnstr)(mbs, n)
48 const char *mbs;
54 __m_trace("insnstr(%p, %d)", mbs, n);
57 code = winsnstr(stdscr, mbs, n);
63 (mvinsnstr)(y, x, mbs, n)
65 const char *mbs; variable
71 __m_trace("mvinsnstr(%d, %d, %p, %d)", y, x, mbs, n);
75 code = winsnstr(stdscr, mbs, n);
81 (mvwinsnstr)(w, y, x, mbs, n)
84 const char *mbs; variable
[all …]
H A Dgetwin.c48 get_cc(w, mbs, fp) in get_cc() argument
50 char *mbs;
60 if (fscanf(fp, "%[^\n]%n ", mbs, &n) < 1)
66 if (mvwaddstr(w, y, x, mbs) == ERR)
78 char *mbs; local
91 if ((mbs = (char *) malloc((size_t) (LINE_MAX+1))) == (char *) 0)
109 by = fscanf( fp, "BG=%hx,%hd,%[^\n] ", &w->_bg._at, &w->_bg._co, mbs);
113 while (get_cc(w, mbs, fp))
119 free(mbs);
125 free(mbs);
[all …]
H A Dkey_name.c56 static char mbs[MB_LEN_MAX+1]; in key_name() local
66 if ((len = wcstombs(mbs, ws, MB_LEN_MAX)) == (size_t) -1) in key_name()
69 mbs[len] = '\0'; in key_name()
72 __m_trace("key_name returned %p = \"%s\".", mbs, mbs); in key_name()
74 return mbs; in key_name()
H A Dwinsnstr.c47 winsnstr(w, mbs, n) in winsnstr() argument
49 const char *mbs;
57 __m_trace("winsnstr(%p, %p, n)", w, mbs, n);
72 for ( ; *mbs != '\0' && 0 < n; n -= i, mbs += i) {
73 if ((i = __m_mbs_cc(mbs, w->_bg._at, w->_bg._co, &cc)) < 0
H A Dm_cc.c53 char *mbs; member
64 sp->mbs[sp->used++] = byte;
76 wistombs(mbs, wis, n) in wistombs() argument
77 char *mbs; in wistombs()
86 string.mbs = mbs;
112 string.mbs[string.used] = '\0';
208 __m_cc_mbs(cc, mbs, n) in __m_cc_mbs() argument
210 char *mbs;
226 string.mbs = mbs;
245 string.mbs[string.used++] = '\0';
[all …]
H A Dwinnstr.c47 winnstr(w, mbs, n) in winnstr() argument
49 char *mbs;
55 __m_trace("winnstr(%p, %p, %d)", w, mbs, n);
65 (void) __m_cc_mbs(&w->_line[y][x], mbs, n);
H A Dslk.c299 char mbs[MB_LEN_MAX * ((1 + M_CCHAR_MAX) * 8) + 1]; in slk_wset() local
333 if (wcstombs(mbs, wcs, sizeof mbs) == (size_t) -1) in slk_wset()
340 if ((__m_screen->_slk._labels[index] = m_strdup(mbs)) == (char *) 0) in slk_wset()
359 (void) mvwaddstr(__m_screen->_slk._w, 0, i, mbs); in slk_wset()
363 plab_norm, (long) index, (long) mbs, in slk_wset()
377 (long) mbs, 0L, 0L, 0L, 0L, 0L, 0L in slk_wset()
/titanic_41/usr/src/lib/libxcurses2/src/libc/xcurses/
H A Dinsnstr.c52 insnstr(const char *mbs, int n) in insnstr() argument
56 code = winsnstr(stdscr, mbs, n); in insnstr()
64 mvinsnstr(int y, int x, const char *mbs, int n) in mvinsnstr() argument
69 code = winsnstr(stdscr, mbs, n); in mvinsnstr()
77 mvwinsnstr(WINDOW *w, int y, int x, const char *mbs, int n) in mvwinsnstr() argument
82 code = winsnstr(w, mbs, n); in mvwinsnstr()
90 insstr(const char *mbs) in insstr() argument
94 code = winsnstr(stdscr, mbs, -1); in insstr()
102 mvinsstr(int y, int x, const char *mbs) in mvinsstr() argument
107 code = winsnstr(stdscr, mbs, -1); in mvinsstr()
[all …]
H A Dgetwin.c54 get_cc(WINDOW *w, char *mbs, FILE *fp) in get_cc() argument
63 if (fscanf(fp, "%[^\n]%n ", mbs, &n) < 1) in get_cc()
69 if (mvwaddstr(w, y, x, mbs) == ERR) in get_cc()
80 char *mbs; in getwin() local
89 if ((mbs = (char *) malloc((size_t) (LINE_MAX+1))) == NULL) in getwin()
106 by = fscanf(fp, "BG=%hx,%hd,%[^\n] ", &w->_bg._at, &w->_bg._co, mbs); in getwin()
110 while (get_cc(w, mbs, fp)) in getwin()
116 free(mbs); in getwin()
122 free(mbs); in getwin()
131 char *mbs, int len, FILE *fp) in put_cc() argument
[all …]
H A Dslk.c337 char mbs[_LABEL_LENGTH_MALLOC]; in slk_wset() local
366 if (wcstombs(tmbs, wcs, sizeof (mbs)) == (size_t) -1) in slk_wset()
370 (void) strcpy(mbs, tmbs); in slk_wset()
374 (void) strcpy(mbs, tmbs); in slk_wset()
375 (void) strncat(mbs, spcs, (8 - width)); in slk_wset()
376 *(mbs + strlen(tmbs) + (8 - width)) = '\0'; in slk_wset()
380 (void) strncpy(mbs, spcs, left1); in slk_wset()
381 (void) strcpy(mbs + left1, tmbs); in slk_wset()
383 (void) strncat(mbs, spcs, left2); in slk_wset()
384 *(mbs + left1 + strlen(tmbs) + left2) = '\0'; in slk_wset()
[all …]
H A Dkey_name.c57 static char mbs[MB_LEN_MAX + 1]; in key_name() local
64 if ((len = wcstombs(mbs, ws, MB_LEN_MAX)) == (size_t) -1) in key_name()
67 mbs[len] = '\0'; in key_name()
69 return (mbs); in key_name()
H A Dwinsnstr.c52 winsnstr(WINDOW *w, const char *mbs, int n) in winsnstr() argument
71 for (; *mbs != '\0' && 0 < n; n -= i, mbs += i) { in winsnstr()
72 if ((i = __m_mbs_cc(mbs, w->_bg._at, w->_fg._co, &cc)) in winsnstr()
H A Dwinnstr.c53 winnstr(WINDOW *w, char *mbs, int n) in winnstr() argument
64 (void) __m_cc_mbs(&w->_line[y][x], mbs, n); in winnstr()
78 return ((int)strlen(mbs)); in winnstr()
H A Dm_cc.c56 char *mbs; member
65 sp->mbs[sp->used++] = (char)byte; in write_string()
77 wistombs(char *mbs, const wint_t *wis, int n) in wistombs() argument
84 string.mbs = mbs; in wistombs()
112 string.mbs[string.used] = '\0'; in wistombs()
216 __m_cc_mbs(const cchar_t *cc, char *mbs, int n) in __m_cc_mbs() argument
229 string.mbs = mbs; in __m_cc_mbs()
247 string.mbs[string.used++] = '\0'; in __m_cc_mbs()
291 __m_mbs_cc(const char *mbs, attr_t at, short co, cchar_t *cc) in __m_mbs_cc() argument
297 for (start = mbs, have_one = i = 0; *mbs != '\0'; mbs += nbytes, ++i) { in __m_mbs_cc()
[all …]
/titanic_41/usr/src/lib/libc/port/locale/
H A Dregexec.c63 xmbrtowc(wint_t *wi, const char *s, size_t n, mbstate_t *mbs, wint_t dummy) in xmbrtowc() argument
68 nr = mbrtowc(&wc, s, n, mbs); in xmbrtowc()
74 (void) memset(mbs, 0, sizeof (*mbs)); in xmbrtowc()
83 xmbrtowc_dummy(wint_t *wi, const char *s, size_t n, mbstate_t *mbs, in xmbrtowc_dummy() argument
87 _NOTE(ARGUNUSED(mbs)); in xmbrtowc_dummy()
119 #define ZAPSTATE(mbs) ((void)(mbs)) argument
174 #define ZAPSTATE(mbs) ((void)(mbs)) argument
185 #define ZAPSTATE(mbs) (void) memset((mbs), 0, sizeof (*(mbs))) argument
H A Dwcsftime.c65 mbstate_t mbs; in __wcsftime_xpg5() local
78 mbs = initial; in __wcsftime_xpg5()
80 sflen = wcsrtombs(NULL, &formatp, 0, &mbs); in __wcsftime_xpg5()
85 mbs = initial; in __wcsftime_xpg5()
86 (void) wcsrtombs(sformat, &formatp, sflen + 1, &mbs); in __wcsftime_xpg5()
104 mbs = initial; in __wcsftime_xpg5()
105 n = mbsrtowcs(wcs, &dstp, maxsize, &mbs); in __wcsftime_xpg5()
H A Dmbftowc.c41 mbstate_t mbs; in _mbftowc() local
55 (void) memset(&mbs, 0, sizeof (mbs)); in _mbftowc()
56 cons = mbrtowc(wc, start, s - start, &mbs); in _mbftowc()
H A Dwcstombs.c42 mbstate_t mbs; in wcstombs_l() local
45 mbs = initial; in wcstombs_l()
47 return (loc->ctype->lc_wcsnrtombs(s, &pwcsp, ULONG_MAX, n, &mbs)); in wcstombs_l()
H A Dungetwc.c57 char mbs[MB_LEN_MAX]; in __ungetwc_impl() local
72 n = wctomb(mbs, (wchar_t)wc); in __ungetwc_impl()
91 p = (unsigned char *)(mbs + n - 1); in __ungetwc_impl()
H A Dwctob.c41 mbstate_t mbs = initial; in wctob_l() local
44 if (c == WEOF || wcrtomb_l(buf, c, &mbs, loc) != 1) in wctob_l()
H A Dwctomb.c39 mbstate_t mbs = { 0 }; in wctomb_l() local
46 if ((rval = wcrtomb_l(s, wchar, &mbs, loc)) == (size_t)-1) in wctomb_l()
/titanic_41/usr/src/cmd/make/bin/
H A Dmacro.cc116 register char *mbs, *tmp_mbs_buffer = NULL; in setvar_envvar() local
129 mbs = tmp_mbs_buffer = getmem((length + 1) * MB_LEN_MAX); in setvar_envvar()
130 (void) wcstombs(mbs, in setvar_envvar()
134 mbs = mbs_buffer; in setvar_envvar()
135 WCSTOMBS(mbs, value.buffer.start); in setvar_envvar()
137 length = 2 + strlen(p->name->string_mb) + strlen(mbs); in setvar_envvar()
146 mbs); in setvar_envvar()
/titanic_41/usr/src/common/smbsrv/
H A Dsmb_utf8.c257 smb_wcequiv_strlen(const char *mbs) in smb_wcequiv_strlen() argument
263 while (*mbs) { in smb_wcequiv_strlen()
264 bytes = smb_mbtowc(&wide_char, mbs, MTS_MB_CHAR_MAX); in smb_wcequiv_strlen()
269 mbs += bytes; in smb_wcequiv_strlen()
282 smb_sbequiv_strlen(const char *mbs) in smb_sbequiv_strlen() argument
288 while (*mbs) { in smb_sbequiv_strlen()
289 nbytes = smb_mbtowc(&wide_char, mbs, MTS_MB_CHAR_MAX); in smb_sbequiv_strlen()
298 mbs += nbytes; in smb_sbequiv_strlen()
/titanic_41/usr/src/lib/libast/common/sfio/
H A Dsfvscanf.c144 SFMBDCL(mbs)
163 SFMBCLR(&mbs);
181 if((flags&SFFMT_LONG) && (n = (int)SFMBLEN(form,&mbs)) <= 0)
205 SFMBDCL(mbs)
207 SFMBCLR(&mbs);
220 if((n = mbrtowc(&fwc, form, ac->endf-form, &mbs)) > 1 &&
230 #define SFgetwc(sc,wc,fmt,ac,mbs) _sfgetwc(sc,wc,fmt,ac,(Void_t*)(mbs)) argument
232 #define SFgetwc(sc,wc,fmt,ac,mbs) _sfgetwc(sc,wc,fmt,ac,NIL(Void_t*)) argument
236 static int _sfgetwc(Scan_t* sc, wchar_t* wc, int fmt, Accept_t* ac, Void_t *mbs) in _sfgetwc() argument
238 static int _sfgetwc(sc, wc, fmt, ac, mbs) in _sfgetwc()
[all …]

123