Changeset 5219 for trunk/oscam-http.c
- Timestamp:
- 05/11/11 00:31:28 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/oscam-http.c
r5214 r5219 3056 3056 char *send_oscam_image(struct templatevars *vars, FILE *f, struct uriparams *params, char *image, time_t modifiedheader, uint32_t etagheader) { 3057 3057 char *wanted; 3058 int8_t disktpl = 0;3059 3058 if(image == NULL) wanted = getParam(params, "i"); 3060 3059 else wanted = image; 3061 3060 if(strlen(wanted) > 3 && wanted[0] == 'I' && wanted[1] == 'C'){ 3062 if(strlen(cfg.http_tpl) > 0){ 3063 char path[255]; 3064 if(strlen(tpl_getTplPath(wanted, cfg.http_tpl, path, 255)) > 0 && file_exists(path)){ 3065 struct stat st; 3066 disktpl = 1; 3067 stat(path, &st); 3068 if(st.st_mtime < modifiedheader){ 3069 send_header304(f); 3070 return "1"; 3071 } 3061 if(etagheader == 0){ 3062 int8_t disktpl = 0; 3063 if(strlen(cfg.http_tpl) > 0){ 3064 char path[255]; 3065 if(strlen(tpl_getTplPath(wanted, cfg.http_tpl, path, 255)) > 0 && file_exists(path)){ 3066 struct stat st; 3067 disktpl = 1; 3068 stat(path, &st); 3069 if(st.st_mtime < modifiedheader){ 3070 send_header304(f); 3071 return "1"; 3072 } 3073 } 3072 3074 } 3073 } 3074 if(disktpl == 0 && first_client->login < modifiedheader){ 3075 send_header304(f);3076 return "1";3075 if(disktpl == 0 && first_client->login < modifiedheader){ 3076 send_header304(f); 3077 return "1"; 3078 } 3077 3079 } 3078 3080 char *header = strstr(tpl_getTpl(vars, wanted), "data:");
Note:
See TracChangeset
for help on using the changeset viewer.