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

/PHP_5_5/ext/ereg/regex/
H A Dregcomp.c1005 register size_t nbytes; local
1014 nbytes = nc / CHAR_BIT * css;
1021 p->g->setbits = (uch *)malloc(nbytes);
1024 nbytes);
1030 (void) memset((unsigned char *)p->g->setbits + (nbytes - css),
/PHP_5_5/ext/fileinfo/libmagic/
H A Dencoding.c68 file_encoding(struct magic_set *ms, const unsigned char *buf, size_t nbytes, unichar **ubuf, size_t *ulen, const char **code, const char **code_mime, const char **type) argument
75 mlen = (nbytes + 1) * sizeof(nbuf[0]);
80 mlen = (nbytes + 1) * sizeof((*ubuf)[0]);
86 if (looks_ascii(buf, nbytes, *ubuf, ulen)) {
90 } else if (looks_utf8_with_BOM(buf, nbytes, *ubuf, ulen) > 0) {
94 } else if (file_looks_utf8(buf, nbytes, *ubuf, ulen) > 1) {
99 } else if ((ucs_type = looks_ucs16(buf, nbytes, *ubuf, ulen)) != 0) {
108 } else if (looks_latin1(buf, nbytes, *ubuf, ulen)) {
112 } else if (looks_extended(buf, nbytes, *ubuf, ulen)) {
117 from_ebcdic(buf, nbytes, nbu
221 looks_ascii(const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t *ulen) argument
241 looks_latin1(const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t *ulen) argument
260 looks_extended(const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t *ulen) argument
291 file_looks_utf8(const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t *ulen) argument
362 looks_utf8_with_BOM(const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t *ulen) argument
372 looks_ucs16(const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t *ulen) argument
493 from_ebcdic(const unsigned char *buf, size_t nbytes, unsigned char *out) argument
[all...]
H A Dis_tar.c63 file_is_tar(struct magic_set *ms, const unsigned char *buf, size_t nbytes) argument
75 tar = is_tar(buf, nbytes);
93 is_tar(const unsigned char *buf, size_t nbytes) argument
100 if (nbytes < sizeof(union record))
H A Dcompress.c103 const unsigned char *buf, size_t nbytes)
117 if (nbytes < compr[i].maglen)
121 nbytes)) != NODATA) {
134 file_buffer(ms, -1, NULL, buf, nbytes) == -1)
245 size_t nbytes)
275 if (swrite(tfd, startbuf, nbytes) != (ssize_t)nbytes)
102 file_zmagic(struct magic_set *ms, int fd, const char *name, const unsigned char *buf, size_t nbytes) argument
244 file_pipe2file(struct magic_set *ms, int fd, const void *startbuf, size_t nbytes) argument
H A Delfclass.h27 if (nbytes <= sizeof(elfhdr))
H A Dreadelf.c1137 size_t nbytes)
1170 fd = file_pipe2file(ms, fd, buf, nbytes);
1136 file_tryelf(struct magic_set *ms, int fd, const unsigned char *buf, size_t nbytes) argument
H A Dmagic.c354 ssize_t nbytes = 0; /* number of bytes read from a datafile */ local
407 if ((nbytes = php_stream_read(stream, (char *)buf, HOWMANY)) < 0) {
412 (void)memset(buf + nbytes, 0, SLOP); /* NUL terminate */
413 if (file_buffer(ms, stream, inname, buf, (size_t)nbytes) == -1)
H A Dascmagic.c62 trim_nuls(const unsigned char *buf, size_t nbytes) argument
64 while (nbytes > 1 && buf[nbytes - 1] == '\0')
65 nbytes--;
67 return nbytes;
71 file_ascmagic(struct magic_set *ms, const unsigned char *buf, size_t nbytes, argument
85 nbytes = trim_nuls(buf, nbytes);
88 if (file_encoding(ms, buf, nbytes, &ubuf, &ulen, &code, &code_mime,
92 rv = file_ascmagic_with_encoding(ms, buf, nbytes, ubu
101 file_ascmagic_with_encoding(struct magic_set *ms, const unsigned char *buf, size_t nbytes, unichar *ubuf, size_t ulen, const char *code, const char *type, int text) argument
[all...]
H A Dreadcdf.c227 size_t nbytes)
240 info.i_len = nbytes;
226 file_trycdf(struct magic_set *ms, int fd, const unsigned char *buf, size_t nbytes) argument
H A Dsoftmagic.c76 /*ARGSUSED1*/ /* nbytes passed for regularity, maybe need later */
78 file_softmagic(struct magic_set *ms, const unsigned char *buf, size_t nbytes, argument
84 if ((rv = match(ms, ml->magic, ml->nmagic, buf, nbytes, 0, mode,
121 const unsigned char *s, size_t nbytes, size_t offset, int mode, int text,
159 switch (mget(ms, s, m, nbytes, offset, cont_level, mode, text,
246 switch (mget(ms, s, m, nbytes, offset, cont_level, mode,
1006 const unsigned char *s, uint32_t offset, size_t nbytes, struct magic *m)
1016 ms->search.s_len = nbytes - offset;
1034 if (bytecnt > nbytes) {
1035 bytecnt = nbytes;
120 match(struct magic_set *ms, struct magic *magic, uint32_t nmagic, const unsigned char *s, size_t nbytes, size_t offset, int mode, int text, int flip, int recursion_level, int *printed_something, int *need_separator, int *returnval) argument
1005 mcopy(struct magic_set *ms, union VALUETYPE *p, int type, int indir, const unsigned char *s, uint32_t offset, size_t nbytes, struct magic *m) argument
1124 mget(struct magic_set *ms, const unsigned char *s, struct magic *m, size_t nbytes, size_t o, unsigned int cont_level, int mode, int text, int flip, int recursion_level, int *printed_something, int *need_separator, int *returnval) argument
[all...]
/PHP_5_5/ext/iconv/
H A Diconv.c199 static php_iconv_err_t _php_iconv_strlen(unsigned int *pretval, const char *str, size_t nbytes, const char *enc);
201 static php_iconv_err_t _php_iconv_substr(smart_str *pretval, const char *str, size_t nbytes, int offset, int len, const char *enc);
642 static php_iconv_err_t _php_iconv_strlen(unsigned int *pretval, const char *str, size_t nbytes, const char *enc) argument
676 for (in_p = str, in_left = nbytes, cnt = 0; in_left > 0; cnt+=2) {
726 const char *str, size_t nbytes, int offset, int len, const char *enc)
743 err = _php_iconv_strlen(&total_len, str, nbytes, enc);
797 for (in_p = str, in_left = nbytes, cnt = 0; in_left > 0 && len > 0; ++cnt) {
725 _php_iconv_substr(smart_str *pretval, const char *str, size_t nbytes, int offset, int len, const char *enc) argument
/PHP_5_5/ext/mbstring/
H A Dmbstring.c4608 MBSTRING_API char *php_mb_safe_strrchr_ex(const char *s, unsigned int c, size_t nbytes, const mbfl_encoding *enc) argument
4613 if (nbytes == (size_t)-1) {
4630 register size_t bcnt = nbytes;
4649 MBSTRING_API char *php_mb_safe_strrchr(const char *s, unsigned int c, size_t nbytes TSRMLS_DC)
4651 return php_mb_safe_strrchr_ex(s, c, nbytes, MBSTRG(internal_encoding));
H A Dmbstring.h132 size_t nbytes, const mbfl_encoding *enc);
134 size_t nbytes TSRMLS_DC);
/PHP_5_5/netware/
H A Dstart.c45 size_t nbytes, size_t *bytesRead, void *buffer ),
36 _NonAppStart( void *NLMHandle, void *errorScreen, const char *cmdLine, const char *loadDirPath, size_t uninitializedDataLength, void *NLMFileHandle, int (*readRoutineP)( int conn, void *fileHandle, size_t offset, size_t nbytes, size_t *bytesRead, void *buffer ), size_t customDataOffset, size_t customDataSize, int messageCount, const char **messages ) argument
/PHP_5_5/ext/gd/libgd/
H A Dgd_jpeg.c600 ssize_t nbytes = 0; local
606 while (nbytes < INPUT_BUF_SIZE) {
607 int got = gdGetBuf(src->buffer + nbytes, INPUT_BUF_SIZE - nbytes, src->infile);
611 if (!nbytes) {
612 nbytes = -1;
616 nbytes += got;
619 if (nbytes <= 0) {
627 nbytes = 2;
631 src->pub.bytes_in_buffer = nbytes;
[all...]
/PHP_5_5/ext/pgsql/
H A Dpgsql.c3371 int buf_len = PGSQL_LO_READ_BUF_SIZE, nbytes, argc = ZEND_NUM_ARGS(); local
3386 if ((nbytes = lo_read((PGconn *)pgsql->conn, pgsql->lofd, buf, buf_len))<0) {
3391 buf[nbytes] = '\0';
3392 RETURN_STRINGL(buf, nbytes, 0);
3403 int str_len, nbytes; local
3429 if ((nbytes = lo_write((PGconn *)pgsql->conn, pgsql->lofd, str, len)) == -1) {
3433 RETURN_LONG(nbytes);
3443 volatile int nbytes; local
3454 while ((nbytes = lo_read((PGconn *)pgsql->conn, pgsql->lofd, buf, PGSQL_LO_READ_BUF_SIZE))>0) {
3455 PHPWRITE(buf, nbytes);
[all...]
/PHP_5_5/ext/odbc/
H A Dphp_odbc.c1423 int fp, nbytes; local
1427 while ((nbytes = read(fp, &buf, 4096)) > 0) {
1428 SQLPutData(result->stmt, (void*)&buf, nbytes);

Completed in 69 milliseconds