From 24d50449943959c89eb5a49962ccc440c44a0e1f Mon Sep 17 00:00:00 2001 From: Russ Allbery Date: Fri, 27 Jun 2008 21:26:13 -0700 Subject: [PATCH] Fix the path for fstrace message catalogs Apply quilt patch fstrace-paths: fstrace uses the NLS functions to do message translation and needs a message catalog installed. The default paths are rather broken. Patch the source to look for it in /usr/share/openafs instead. Not suitable upstream with the hard-coded paths, but something more sophisticated would be appropriate. --- debian/patches/fstrace-paths | 27 --------------------------- src/venus/fstrace.c | 5 +++-- 2 files changed, 3 insertions(+), 29 deletions(-) delete mode 100644 debian/patches/fstrace-paths diff --git a/debian/patches/fstrace-paths b/debian/patches/fstrace-paths deleted file mode 100644 index 728e193a0..000000000 --- a/debian/patches/fstrace-paths +++ /dev/null @@ -1,27 +0,0 @@ -fstrace uses the NLS functions to do message translation and needs a -message catalog installed. The default paths are rather broken. Patch -the source to look for it in /usr/share/openafs instead. Not suitable -upstream with the hard-coded paths, but something more sophisticated -would be appropriate. - ---- openafs.orig/src/venus/fstrace.c -+++ openafs/src/venus/fstrace.c -@@ -1466,7 +1466,7 @@ - */ - - #ifndef RPC_NLS_FORMAT --#define RPC_NLS_FORMAT "%s.cat" -+#define RPC_NLS_FORMAT "/usr/share/openafs/%s.cat" - #endif - - dce1_error_inq_text(status_to_convert, error_text, status) -@@ -1483,7 +1483,8 @@ - char component_name[4]; - char *facility_name; - char filename_prefix[7]; -- char nls_filename[11]; -+ /* strlen("/usr/share/openafs/") + 6 + strlen(".cat") + 1 */ -+ char nls_filename[19 + 6 + 4 + 1]; - char alt_filename[80]; - char *message; - #if defined(AFS_64BITPOINTER_ENV) diff --git a/src/venus/fstrace.c b/src/venus/fstrace.c index 200b6fefe..ac9ce087f 100644 --- a/src/venus/fstrace.c +++ b/src/venus/fstrace.c @@ -1466,7 +1466,7 @@ catgets1(nl_catd catd, int setno, int msgno, char *def) */ #ifndef RPC_NLS_FORMAT -#define RPC_NLS_FORMAT "%s.cat" +#define RPC_NLS_FORMAT "/usr/share/openafs/%s.cat" #endif dce1_error_inq_text(status_to_convert, error_text, status) @@ -1483,7 +1483,8 @@ dce1_error_inq_text(status_to_convert, error_text, status) char component_name[4]; char *facility_name; char filename_prefix[7]; - char nls_filename[11]; + /* strlen("/usr/share/openafs/") + 6 + strlen(".cat") + 1 */ + char nls_filename[19 + 6 + 4 + 1]; char alt_filename[80]; char *message; #if defined(AFS_64BITPOINTER_ENV) -- 2.39.5