Home
last modified time | relevance | path

Searched refs:sce (Results 1 – 25 of 27) sorted by relevance

12

/mOS-networking-stack/samples/lighttpd-1.4.32/src/
H A Dstat_cache.c125 sce = calloc(1, sizeof(*sce)); in stat_cache_entry_init()
131 return sce; in stat_cache_entry_init()
136 if (!sce) return; in stat_cache_entry_free()
142 free(sce); in stat_cache_entry_free()
471 *ret_sce = sce; in stat_cache_get_entry()
503 if (NULL == sce) { in stat_cache_get_entry()
530 sce->st = st; in stat_cache_get_entry()
622 etag_create(sce->etag, &(sce->st), con->etag_flags); in stat_cache_get_entry()
624 etag_create(sce->etag, &(sce->st), con->etag_flags); in stat_cache_get_entry()
676 *ret_sce = sce; in stat_cache_get_entry()
[all …]
H A Dmod_compress.c421 if ((off_t)(sce->st.st_size * 1.1) < sce->st.st_size) return -1; in deflate_file_to_file()
512 if (NULL == start || sce->st.st_size != read(ifd, start, sce->st.st_size)) { in deflate_file_to_file()
532 ret = deflate_file_to_buffer_gzip(srv, con, p, start, sce->st.st_size, sce->st.st_mtime); in deflate_file_to_file()
561 munmap(start, sce->st.st_size); in deflate_file_to_file()
590 if ((off_t)(sce->st.st_size * 1.1) < sce->st.st_size) return -1; in deflate_file_to_buffer()
615 if (NULL == start || sce->st.st_size != read(ifd, start, sce->st.st_size)) { in deflate_file_to_buffer()
628 ret = deflate_file_to_buffer_gzip(srv, con, p, start, sce->st.st_size, sce->st.st_mtime); in deflate_file_to_buffer()
724 stat_cache_entry *sce = NULL; in PHYSICALPATH_FUNC() local
780 if (sce->content_type->ptr) { in PHYSICALPATH_FUNC()
784 buffer_copy_string_len(content_type, sce->content_type->ptr, c - sce->content_type->ptr); in PHYSICALPATH_FUNC()
[all …]
H A Dmod_staticfile.c161 stat_cache_entry *sce = NULL; in http_response_parse_range() local
169 end = sce->st.st_size - 1; in http_response_parse_range()
196 end = sce->st.st_size - 1; in http_response_parse_range()
197 start = sce->st.st_size + le; in http_response_parse_range()
202 end = sce->st.st_size - 1; in http_response_parse_range()
203 start = sce->st.st_size + le; in http_response_parse_range()
219 end = sce->st.st_size - 1; in http_response_parse_range()
226 end = sce->st.st_size - 1; in http_response_parse_range()
276 if (end > sce->st.st_size - 1) end = sce->st.st_size - 1; in http_response_parse_range()
360 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
[all …]
H A Dnetwork_write.c91 stat_cache_entry *sce = NULL; in network_write_chunkqueue_write() local
94 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_write()
105 if (offset > sce->st.st_size) { in network_write_chunkqueue_write()
118 if (MAP_FAILED == (p = mmap(0, sce->st.st_size, PROT_READ, MAP_SHARED, ifd, 0))) { in network_write_chunkqueue_write()
135 munmap(p, sce->st.st_size); in network_write_chunkqueue_write()
140 munmap(p, sce->st.st_size); in network_write_chunkqueue_write()
146 munmap(p, sce->st.st_size); in network_write_chunkqueue_write()
H A Dmod_magnet.c256 stat_cache_entry *sce = NULL; in magnet_stat() local
300 lua_pushinteger(L, sce->st.st_mtime); in magnet_stat()
309 lua_pushinteger(L, sce->st.st_uid); in magnet_stat()
312 lua_pushinteger(L, sce->st.st_gid); in magnet_stat()
315 lua_pushinteger(L, sce->st.st_size); in magnet_stat()
318 lua_pushinteger(L, sce->st.st_ino); in magnet_stat()
322 if (!buffer_is_empty(sce->etag)) { in magnet_stat()
325 etag_mutate(b, sce->etag); in magnet_stat()
335 lua_pushlstring(L, sce->content_type->ptr, sce->content_type->used - 1); in magnet_stat()
767 stat_cache_entry *sce; in magnet_attach_content() local
[all …]
H A Dmod_magnet_cache.c60 stat_cache_entry *sce; in script_cache_get_script() local
72 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, sc->name, &sce)) { in script_cache_get_script()
77 if (!buffer_is_equal(sce->etag, sc->etag)) { in script_cache_get_script()
121 if (HANDLER_GO_ON == stat_cache_get_entry(srv, con, sc->name, &sce)) { in script_cache_get_script()
122 buffer_copy_string_buffer(sc->etag, sce->etag); in script_cache_get_script()
H A Dnetwork_mtcp_writev.c155 stat_cache_entry *sce = NULL;
163 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) {
171 if (abs_offset > sce->st.st_size) {
410 stat_cache_entry *sce = NULL; in network_write_chunkqueue_mtcp_writev() local
413 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_mtcp_writev()
424 if (offset > sce->st.st_size) { in network_write_chunkqueue_mtcp_writev()
438 if (MAP_FAILED == (p = mmap(0, sce->st.st_size, PROT_READ, MAP_SHARED, ifd, 0))) { in network_write_chunkqueue_mtcp_writev()
455 munmap(p, sce->st.st_size); in network_write_chunkqueue_mtcp_writev()
460 munmap(p, sce->st.st_size); in network_write_chunkqueue_mtcp_writev()
466 munmap(p, sce->st.st_size); in network_write_chunkqueue_mtcp_writev()
H A Dnetwork_freebsd_sendfile.c135 stat_cache_entry *sce = NULL; in network_write_chunkqueue_freebsdsendfile() local
137 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_freebsdsendfile()
181 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_freebsdsendfile()
186 if (offset >= sce->st.st_size) { in network_write_chunkqueue_freebsdsendfile()
H A Dresponse.c560 stat_cache_entry *sce = NULL; in http_response_prepare() local
567 if (HANDLER_ERROR != stat_cache_get_entry(srv, con, con->physical.path, &sce)) { in http_response_prepare()
575 if ((sce->is_symlink != 0) && !con->conf.follow_symlink) { in http_response_prepare()
587 if (S_ISDIR(sce->st.st_mode)) { in http_response_prepare()
596 } else if (!S_ISREG(sce->st.st_mode) && !sce->is_symlink) { in http_response_prepare()
598 } else if (!S_ISREG(sce->st.st_mode)) { in http_response_prepare()
655 if (HANDLER_ERROR != stat_cache_get_entry(srv, con, con->physical.path, &sce)) { in http_response_prepare()
656 found = S_ISREG(sce->st.st_mode); in http_response_prepare()
689 if ((sce->is_symlink != 0) && !con->conf.follow_symlink) { in http_response_prepare()
H A Dmod_flv_streaming.c209 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
236 if (HANDLER_GO_ON != stat_cache_get_entry(srv, con, con->physical.path, &sce)) { in URIHANDLER_FUNC()
240 if (start > sce->st.st_size) { in URIHANDLER_FUNC()
248 http_chunk_append_file(srv, con, con->physical.path, start, sce->st.st_size - start); in URIHANDLER_FUNC()
H A Dnetwork_solaris_sendfilev.c143 stat_cache_entry *sce = NULL; in network_write_chunkqueue_solarissendfilev() local
146 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_solarissendfilev()
156 if (offset > sce->st.st_size) { in network_write_chunkqueue_solarissendfilev()
H A Dmod_cml_lua.c336 stat_cache_entry *sce = NULL; in cache_parse_lua() local
350 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, b, &sce)) { in cache_parse_lua()
377 chunkqueue_append_file(con->write_queue, b, 0, sce->st.st_size); in cache_parse_lua()
378 if (sce->st.st_mtime > mtime) mtime = sce->st.st_mtime; in cache_parse_lua()
H A Dmod_ssi.c368 stat_cache_entry *sce = NULL; in process_ssi_stmt() local
437 stat_cache_get_entry(srv, con, con->physical.path, &sce); in process_ssi_stmt()
445 if (NULL == (pw = getpwuid(sce->st.st_uid))) { in process_ssi_stmt()
446 buffer_copy_long(b, sce->st.st_uid); in process_ssi_stmt()
451 buffer_copy_long(b, sce->st.st_uid); in process_ssi_stmt()
456 time_t t = sce->st.st_mtime; in process_ssi_stmt()
1084 stat_cache_entry *sce = NULL; in mod_ssi_handle_request() local
1088 stat_cache_get_entry(srv, con, con->physical.path, &sce); in mod_ssi_handle_request()
1090 etag_mutate(con->physical.etag, sce->etag); in mod_ssi_handle_request()
1093 if (sce->st.st_mtime > include_file_last_mtime) in mod_ssi_handle_request()
[all …]
H A Dnetwork_linux_sendfile.c131 stat_cache_entry *sce = NULL; in network_write_chunkqueue_linuxsendfile() local
180 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_linuxsendfile()
185 if (offset > sce->st.st_size) { in network_write_chunkqueue_linuxsendfile()
H A Dmod_simple_vhost.c125 stat_cache_entry *sce = NULL; in build_doc_root() local
159 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, out, &sce)) { in build_doc_root()
165 } else if (!S_ISDIR(sce->st.st_mode)) { in build_doc_root()
H A Dmod_expire.c307 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
309 stat_cache_get_entry(srv, con, con->physical.path, &sce); in URIHANDLER_FUNC()
319 expires = (ts + sce->st.st_mtime); in URIHANDLER_FUNC()
H A Dnetwork_writev.c155 stat_cache_entry *sce = NULL; in network_write_chunkqueue_writev() local
163 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_writev()
171 if (abs_offset > sce->st.st_size) { in network_write_chunkqueue_writev()
H A Dmod_evhost.c265 stat_cache_entry *sce = NULL; in mod_evhost_uri_handler() local
318 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, p->tmp_buf, &sce)) { in mod_evhost_uri_handler()
321 } else if(!S_ISDIR(sce->st.st_mode)) { in mod_evhost_uri_handler()
H A Dnetwork_openssl.c161 stat_cache_entry *sce = NULL; in network_write_chunkqueue_openssl() local
165 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, c->file.name, &sce)) { in network_write_chunkqueue_openssl()
H A Dmod_rewrite.c452 stat_cache_entry *sce; in URIHANDLER_FUNC() local
462 sce = NULL; in URIHANDLER_FUNC()
463 if (HANDLER_ERROR != stat_cache_get_entry(srv, con, con->physical.path, &sce)) { in URIHANDLER_FUNC()
464 if (S_ISREG(sce->st.st_mode)) return HANDLER_GO_ON; in URIHANDLER_FUNC()
H A Dmod_indexfile.c140 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
167 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, p->tmp_buf, &sce)) { in URIHANDLER_FUNC()
H A Dmod_mysql_vhost.c342 stat_cache_entry *sce; local
388 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, p->tmp_buf, &sce)) {
392 if (!S_ISDIR(sce->st.st_mode)) {
H A Dmod_webdav.c831 stat_cache_entry *sce = NULL; in webdav_get_live_property() local
836 if (HANDLER_ERROR != (stat_cache_get_entry(srv, con, dst->path, &sce))) { in webdav_get_live_property()
842 if (S_ISDIR(sce->st.st_mode)) { in webdav_get_live_property()
847 if (S_ISDIR(sce->st.st_mode)) { in webdav_get_live_property()
850 } else if(S_ISREG(sce->st.st_mode)) { in webdav_get_live_property()
868 strftime(ctime_buf, sizeof(ctime_buf), "%Y-%m-%dT%H:%M:%SZ", gmtime(&(sce->st.st_ctime))); in webdav_get_live_property()
874 strftime(mtime_buf, sizeof(mtime_buf), "%a, %d %b %Y %H:%M:%S GMT", gmtime(&(sce->st.st_mtime))); in webdav_get_live_property()
880 buffer_append_off_t(b, sce->st.st_size); in webdav_get_live_property()
1221 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
1241 switch (stat_cache_get_entry(srv, con, con->physical.path, &sce)) { in URIHANDLER_FUNC()
H A Dmod_dirlisting.c898 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
927 if (HANDLER_ERROR == stat_cache_get_entry(srv, con, con->physical.path, &sce)) { in URIHANDLER_FUNC()
932 if (!S_ISDIR(sce->st.st_mode)) return HANDLER_GO_ON; in URIHANDLER_FUNC()
H A Dmod_cgi.c1243 stat_cache_entry *sce = NULL; in URIHANDLER_FUNC() local
1251 …if (HANDLER_ERROR == stat_cache_get_entry(srv, con, con->physical.path, &sce)) return HANDLER_GO_O… in URIHANDLER_FUNC()
1252 if (!S_ISREG(sce->st.st_mode)) return HANDLER_GO_ON; in URIHANDLER_FUNC()
1253 …if (p->conf.execute_x_only == 1 && (sce->st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH)) == 0) return … in URIHANDLER_FUNC()

12