Home
last modified time | relevance | path

Searched refs:nbytes (Results 1 – 17 of 17) sorted by relevance

/PHP-7.1/ext/fileinfo/libmagic/
H A Dencoding.c79 mlen = (nbytes + 1) * sizeof((*ubuf)[0]); in file_encoding()
84 mlen = (nbytes + 1) * sizeof(nbuf[0]); in file_encoding()
120 from_ebcdic(buf, nbytes, nbuf); in file_encoding()
231 for (i = 0; i < nbytes; i++) { in looks_ascii()
250 for (i = 0; i < nbytes; i++) { in looks_latin1()
270 for (i = 0; i < nbytes; i++) { in looks_extended()
304 for (i = 0; i < nbytes; i++) { in file_looks_utf8()
341 if (i >= nbytes) in file_looks_utf8()
381 if (nbytes < 2) in looks_ucs16()
393 for (i = 2; i + 1 < nbytes; i += 2) { in looks_ucs16()
[all …]
H A Dascmagic.c62 trim_nuls(const unsigned char *buf, size_t nbytes) in trim_nuls() argument
64 while (nbytes > 1 && buf[nbytes - 1] == '\0') in trim_nuls()
65 nbytes--; in trim_nuls()
67 return nbytes; in trim_nuls()
85 nbytes = trim_nuls(buf, nbytes); in file_ascmagic()
88 if (file_encoding(ms, buf, nbytes, &ubuf, &ulen, &code, &code_mime, in file_ascmagic()
92 rv = file_ascmagic_with_encoding(ms, buf, nbytes, ubuf, ulen, code, in file_ascmagic()
102 size_t nbytes, unichar *ubuf, size_t ulen, const char *code, in file_ascmagic_with_encoding() argument
129 nbytes = trim_nuls(buf, nbytes); in file_ascmagic_with_encoding()
132 if (nbytes <= 1) { in file_ascmagic_with_encoding()
[all …]
H A Dis_tar.c63 file_is_tar(struct magic_set *ms, const unsigned char *buf, size_t nbytes) in file_is_tar() argument
75 tar = is_tar(buf, nbytes); in file_is_tar()
93 is_tar(const unsigned char *buf, size_t nbytes) in is_tar() argument
100 if (nbytes < sizeof(union record)) in is_tar()
H A Dsoftmagic.c1109 if (bytecnt > nbytes) { in mcopy()
1110 bytecnt = nbytes; in mcopy()
1153 if (offset >= nbytes) in mcopy()
1177 if (offset >= nbytes) { in mcopy()
1182 nbytes = nbytes - offset; in mcopy()
1184 nbytes = sizeof(*p); in mcopy()
1192 if (nbytes < sizeof(*p)) in mcopy()
1194 sizeof(*p) - nbytes); in mcopy()
1655 if (nbytes < offset) in mget()
1665 if (nbytes < offset) in mget()
[all …]
H A Dcompress.c109 const unsigned char *buf, size_t nbytes) in file_zmagic() argument
126 if (nbytes < compr[i].maglen) in file_zmagic()
130 nbytes)) != NODATA) { in file_zmagic()
140 if (file_buffer(ms, -1, NULL, buf, nbytes) == -1) in file_zmagic()
255 size_t nbytes) in file_pipe2file() argument
285 if (swrite(tfd, startbuf, nbytes) != (ssize_t)nbytes) in file_pipe2file()
H A Dmagic.c356 ssize_t nbytes = 0; /* number of bytes read from a datafile */ in file_or_stream() local
404 if ((nbytes = php_stream_read(stream, (char *)buf, HOWMANY)) < 0) { in file_or_stream()
409 (void)memset(buf + nbytes, 0, SLOP); /* NUL terminate */ in file_or_stream()
410 if (file_buffer(ms, stream, inname, buf, (size_t)nbytes) == -1) in file_or_stream()
H A Delfclass.h27 if (nbytes <= sizeof(elfhdr))
H A Dreadcdf.c442 size_t nbytes) in file_trycdf() argument
455 info.i_len = nbytes; in file_trycdf()
/PHP-7.1/ext/gd/libgd/
H A Dgd_jpeg.c600 ssize_t nbytes = 0; in fill_input_buffer() local
606 while (nbytes < INPUT_BUF_SIZE) { in fill_input_buffer()
607 int got = gdGetBuf(src->buffer + nbytes, INPUT_BUF_SIZE - nbytes, src->infile); in fill_input_buffer()
611 if (!nbytes) { in fill_input_buffer()
612 nbytes = -1; in fill_input_buffer()
616 nbytes += got; in fill_input_buffer()
619 if (nbytes <= 0) { in fill_input_buffer()
627 nbytes = 2; in fill_input_buffer()
631 src->pub.bytes_in_buffer = nbytes; in fill_input_buffer()
/PHP-7.1/netware/
H A Dstart.c45 size_t nbytes, size_t *bytesRead, void *buffer ), in _NonAppStart() argument
/PHP-7.1/ext/mbstring/
H A Dmbstring.h135 size_t nbytes, const mbfl_encoding *enc);
137 size_t nbytes);
H A Dmbstring.c4861 MBSTRING_API char *php_mb_safe_strrchr_ex(const char *s, unsigned int c, size_t nbytes, const mbfl_… in php_mb_safe_strrchr_ex() argument
4866 if (nbytes == (size_t)-1) { in php_mb_safe_strrchr_ex()
4883 register size_t bcnt = nbytes; in php_mb_safe_strrchr_ex()
4902 MBSTRING_API char *php_mb_safe_strrchr(const char *s, unsigned int c, size_t nbytes) in php_mb_safe_strrchr() argument
4904 return php_mb_safe_strrchr_ex(s, c, nbytes, MBSTRG(internal_encoding)); in php_mb_safe_strrchr()
/PHP-7.1/ext/iconv/
H A Diconv.c205 static php_iconv_err_t _php_iconv_strlen(size_t *pretval, const char *str, size_t nbytes, const cha…
207 static php_iconv_err_t _php_iconv_substr(smart_str *pretval, const char *str, size_t nbytes, zend_l…
738 static php_iconv_err_t _php_iconv_strlen(size_t *pretval, const char *str, size_t nbytes, const cha… in _php_iconv_strlen() argument
773 for (in_p = str, in_left = nbytes, cnt = 0; in_left > 0; cnt+=2) { in _php_iconv_strlen()
823 const char *str, size_t nbytes, zend_long offset, zend_long len, const char *enc) in _php_iconv_substr() argument
840 err = _php_iconv_strlen(&total_len, str, nbytes, enc); in _php_iconv_substr()
894 for (in_p = str, in_left = nbytes, cnt = 0; in_left > 0 && len > 0; ++cnt) { in _php_iconv_substr()
/PHP-7.1/ext/fileinfo/
H A Dlibmagic.patch2703 - while ((r = sread(fd, (void *)&buf[nbytes],
2704 - (size_t)(HOWMANY - nbytes), 1)) > 0) {
2705 - nbytes += r;
2709 - if (nbytes == 0) {
2724 - if ((nbytes = read(fd, (char *)buf, howmany)) == -1) {
2737 (void)memset(buf + nbytes, 0, SLOP); /* NUL terminate */
3444 - if (bytecnt == 0 || bytecnt > nbytes - offset)
3445 - bytecnt = nbytes - offset;
3450 + if (bytecnt > nbytes) {
3451 + bytecnt = nbytes;
[all …]
/PHP-7.1/ext/pgsql/
H A Dpgsql.c3530 int nbytes, argc = ZEND_NUM_ARGS(); local
3547 if ((nbytes = lo_read((PGconn *)pgsql->conn, pgsql->lofd, ZSTR_VAL(buf), ZSTR_LEN(buf)))<0) {
3552 ZSTR_LEN(buf) = nbytes;
3565 size_t str_len, nbytes; local
3593 if ((nbytes = lo_write((PGconn *)pgsql->conn, pgsql->lofd, str, len)) == (size_t)-1) {
3597 RETURN_LONG(nbytes);
3607 volatile int nbytes; local
3620 while ((nbytes = lo_read((PGconn *)pgsql->conn, pgsql->lofd, buf, PGSQL_LO_READ_BUF_SIZE))>0) {
3621 PHPWRITE(buf, nbytes);
3622 tbytes += nbytes;
/PHP-7.1/ext/odbc/
H A Dphp_odbc.c1459 int fp, nbytes; in PHP_FUNCTION() local
1463 while ((nbytes = read(fp, &buf, 4096)) > 0) { in PHP_FUNCTION()
1464 SQLPutData(result->stmt, (void*)&buf, nbytes); in PHP_FUNCTION()
/PHP-7.1/ext/standard/
H A Dbasic_functions.c4769 size_t nbytes; local
4789 nbytes = php_stream_write(stream, message, message_len);
4791 if (nbytes != message_len) {

Completed in 112 milliseconds