Search
j0ke.net Open Build Service
>
Projects
>
multimedia
:
SL11
>
transcode
> transcode-configdir.patch
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File transcode-configdir.patch of Package transcode
--- libtc/cfgfile.c.orig 2009-02-21 22:01:57.000000000 +0100 +++ libtc/cfgfile.c 2010-12-14 16:47:22.000000000 +0100 @@ -18,6 +18,7 @@ #include <string.h> #include <ctype.h> +#define DEFAULT_CONFIG_DIR "@@CONFIGDIR@@" static char *config_dir = NULL; static int parse_line(const char *buf, TCConfigEntry *conf, const char *tag, @@ -117,7 +118,7 @@ void tc_set_config_dir(const char *dir) { - tc_free(config_dir); + if (config_dir != NULL) tc_free(config_dir); config_dir = dir ? tc_strdup(dir) : NULL; } @@ -156,7 +157,7 @@ /* Open the file */ tc_snprintf(path_buf, sizeof(path_buf), "%s/%s", - config_dir ? config_dir : ".", filename); + config_dir ? config_dir : DEFAULT_CONFIG_DIR, filename); f = fopen_verbose(path_buf, tag); if (!f) { return 0;