]> gitweb.ps.run Git - ps-cgit/commitdiff
Merge branch 'sn/subject-link'
authorLars Hjemli <hjemli@gmail.com>
Sat, 19 Jun 2010 09:38:46 +0000 (11:38 +0200)
committerLars Hjemli <hjemli@gmail.com>
Sat, 19 Jun 2010 09:38:46 +0000 (11:38 +0200)
1  2 
shared.c

diff --combined shared.c
index 83b71e65c5d1980b60e01cedfb7d253a42f0984b,83ded44de93b4343364ddfacedc94e9672008a02..8b3a0457748a3f3ef30b48c8d1aecffa4a2c6b66
+++ b/shared.c
@@@ -60,6 -60,7 +60,7 @@@ struct cgit_repo *cgit_add_repo(const c
        ret->enable_log_filecount = ctx.cfg.enable_log_filecount;
        ret->enable_log_linecount = ctx.cfg.enable_log_linecount;
        ret->enable_remote_branches = ctx.cfg.enable_remote_branches;
+       ret->enable_subject_links = ctx.cfg.enable_subject_links;
        ret->max_stats = ctx.cfg.max_stats;
        ret->module_link = ctx.cfg.module_link;
        ret->readme = NULL;
@@@ -279,10 -280,6 +280,10 @@@ int cgit_diff_files(const unsigned cha
        if ((file1.ptr && buffer_is_binary(file1.ptr, file1.size)) ||
            (file2.ptr && buffer_is_binary(file2.ptr, file2.size))) {
                *binary = 1;
 +              if (file1.size)
 +                      free(file1.ptr);
 +              if (file2.size)
 +                      free(file2.ptr);
                return 0;
        }
  
        emit_cb.outf = filediff_cb;
        emit_cb.priv = fn;
        xdl_diff(&file1, &file2, &diff_params, &emit_params, &emit_cb);
 +      if (file1.size)
 +              free(file1.ptr);
 +      if (file2.size)
 +              free(file2.ptr);
        return 0;
  }