Lines Matching defs:fb

260 _win_iconv(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
281 memcpy(*tb, *fb, fz);
294 if ((tz = MultiByteToWideChar(cc->from.index, 0, (LPCSTR)*fb, (int)*fn, (LPWSTR)*tb, *tn)) && tz <= *tn)
311 while (!(tz = MultiByteToWideChar(cc->from.index, 0, (LPCSTR)*fb, (int)fz, (LPWSTR)*tb, 0)))
338 ub = (LPWSTR)*fb;
340 else if (!(un = MultiByteToWideChar(cc->from.index, 0, (LPCSTR)*fb, (int)*fn, (LPWSTR)*tb, 0)))
344 else if (!(un = MultiByteToWideChar(cc->from.index, 0, (LPCSTR)*fb, (int)*fn, (LPWSTR)ub, un)))
365 while (!(fz = MultiByteToWideChar(cc->from.index, 0, (LPCSTR)*fb, (int)bz, (LPWSTR)ub, un)))
395 if (ub != (LPWSTR)*fb)
399 *fb += fz;
405 if (ub && ub != (LPWSTR)*fb)
531 utf2bin(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
544 f = (unsigned char*)(*fb);
593 *fn -= (char*)f - (*fb);
594 *fb = (char*)f;
605 bin2utf(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
617 f = (unsigned char*)(*fb);
667 *fn -= (n = (char*)f - (*fb));
668 *fb = (char*)f;
715 ume2bin(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
730 f = (unsigned char*)(*fb);
779 *fn -= (char*)f - (*fb);
780 *fb = (char*)f;
791 bin2ume(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
805 f = (unsigned char*)(*fb);
853 *fn -= (n = (char*)f - (*fb));
854 *fb = (char*)f;
865 ucs2bin(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
876 f = (unsigned char*)(*fb);
898 *fn -= (char*)f - (*fb);
899 *fb = (char*)f;
910 bin2ucs(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
922 f = (unsigned char*)(*fb);
944 *fn -= (n = (char*)f - (*fb));
945 *fb = (char*)f;
956 scu2bin(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
967 f = (unsigned char*)(*fb);
989 *fn -= (char*)f - (*fb);
990 *fb = (char*)f;
1001 bin2scu(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
1013 f = (unsigned char*)(*fb);
1035 *fn -= (n = (char*)f - (*fb));
1036 *fb = (char*)f;
1230 * copy *fb size *fn to *tb size *tn
1231 * fb,fn tb,tn updated on return
1235 _ast_iconv(_ast_iconv_t cd, char** fb, size_t* fn, char** tb, size_t* tn)
1248 if (!fb || !*fb)
1270 tfb = *fb;
1278 *fb += i;
1282 if ((*cc->from.fun)(cc->cvt, fb, fn, tb, tn) == (size_t)(-1))
1296 return (*cc->to.fun)(cc->cvt, fb, fn, tb, tn);
1304 f = (unsigned char*)(*fb);
1310 *fb += b - cc->buf;
1318 f = (unsigned char*)(*fb);
1325 memcpy(*tb, *fb, n);
1326 *fb += n;
1336 * write *fb size *fn to op
1337 * fb,fn updated on return
1342 _ast_iconv_write(_ast_iconv_t cd, Sfio_t* op, char** fb, size_t* fn, Iconv_disc_t* disc)
1344 char* fo = *fb;
1381 while (*fn > 0 && _ast_iconv(cd, fb, fn, &ts, &tn) == (size_t)(-1))
1386 error(DEBUG_TRACE, "AHA#%d iconv_write %d => %d `%-.*s'", __LINE__, *fn, tn, *fn, *fb);
1387 _r = _ast_iconv(cd, fb, fn, &ts, &tn);
1398 (*disc->errorf)(NiL, disc, ERROR_SYSTEM|2, "incomplete multibyte sequence at offset %I*u", sizeof(fo), *fb - fo);
1402 (*disc->errorf)(NiL, disc, ERROR_SYSTEM|2, "invalid multibyte sequence at offset %I*u", sizeof(fo), *fb - fo);
1409 *ts++ = (disc->fill >= 0) ? disc->fill : **fb;
1412 (*fb)++;
1439 char* fb;
1475 if ((!(fb = (char*)sfreserve(ip, n, locked = SF_LOCKR)) || !(fo = sfvalue(ip))) &&
1476 (!(fb = (char*)sfreserve(ip, n, locked = 0)) || !(fo = sfvalue(ip))))
1478 fs = fb;
1529 sfread(ip, fb, fs - fb);
1531 for (i = fn; --i >= (fs - fb);)
1532 sfungetc(ip, fb[i]);
1535 if (n <= (fs - fb))
1537 n -= fs - fb;
1539 ft += (fs - fb);
1543 if (fb && locked)
1544 sfread(ip, fb, 0);