Ignore:
Timestamp:
01/24/11 14:21:29 (10 years ago)
Author:
dingo35
Message:

All files: make cfg static for easier valgrind analysis

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/oscam-http-helpers.c

    r4481 r4588  
    189189  }
    190190
    191   if(strlen(cfg->http_tpl) > 0){
     191  if(strlen(cfg.http_tpl) > 0){
    192192    char path[255];
    193     if(strlen(tpl_getTplPath(name, cfg->http_tpl, path, 255)) > 0 && file_exists(path)){
     193    if(strlen(tpl_getTplPath(name, cfg.http_tpl, path, 255)) > 0 && file_exists(path)){
    194194            FILE *fp;
    195195            char buffer[1024];
     
    325325    char *uri = "";
    326326    char *username = "";
    327     char *expectedPassword = cfg->http_pwd;
     327    char *expectedPassword = cfg.http_pwd;
    328328    char *pch = authstring + 22;
    329329    char *pch2;
     
    357357        if(strncmp(pch2, path, strlen(path)) == 0) uriok = 1;
    358358    }
    359     if(uriok == 1 && strcmp(username, cfg->http_user) == 0){
     359    if(uriok == 1 && strcmp(username, cfg.http_user) == 0){
    360360        char A1tmp[3 + strlen(username) + strlen(AUTHREALM) + strlen(expectedPassword)];
    361361        char A1[(MD5_DIGEST_LENGTH * 2) + 1], A2[(MD5_DIGEST_LENGTH * 2) + 1], A3[(MD5_DIGEST_LENGTH * 2) + 1];
     
    388388int webif_write_raw(char *buf, FILE* f, int len) {
    389389#ifdef WITH_SSL
    390     if (cfg->http_use_ssl) {
     390    if (cfg.http_use_ssl) {
    391391        return SSL_write((SSL*)f, buf, len);
    392392    } else
     
    401401int webif_read(char *buf, int num, FILE *f) {
    402402#ifdef WITH_SSL
    403     if (cfg->http_use_ssl) {
     403    if (cfg.http_use_ssl) {
    404404        return SSL_read((SSL*)f, buf, num);
    405405    } else
     
    446446
    447447    if (!strcmp(filename, "CSS")){
    448         filename = cfg->http_css;
     448        filename = cfg.http_css;
    449449        fileno = 1;
    450450    } else if (!strcmp(filename, "JS")){
    451         filename = cfg->http_jscript;
     451        filename = cfg.http_jscript;
    452452        fileno = 2;
    453453    }
Note: See TracChangeset for help on using the changeset viewer.