diff options
-rw-r--r-- | Build/source/texk/dvipsk/ChangeLog | 4 | ||||
-rw-r--r-- | Build/source/texk/dvipsk/output.c | 20 |
2 files changed, 20 insertions, 4 deletions
diff --git a/Build/source/texk/dvipsk/ChangeLog b/Build/source/texk/dvipsk/ChangeLog index be235c6e704..c64c7e908a8 100644 --- a/Build/source/texk/dvipsk/ChangeLog +++ b/Build/source/texk/dvipsk/ChangeLog @@ -1,3 +1,7 @@ +2011-02-14 Akira Kakuto <kakuto@fuk.kindai.ac.jp> + + * output.c: print R2 mode message only when secure == 2. + 2011-01-29 Karl Berry <karl@tug.org> * search.c (search): report the actual popen call if D_FILES. diff --git a/Build/source/texk/dvipsk/output.c b/Build/source/texk/dvipsk/output.c index dacbf1f0fe2..ae5cf86b29f 100644 --- a/Build/source/texk/dvipsk/output.c +++ b/Build/source/texk/dvipsk/output.c @@ -126,13 +126,22 @@ copyfile_general(const char *s, struct header_list *cur_header) if ( NULL != lastdirsep ) trunc_s = lastdirsep + 1; #ifdef VMCMS sprintf(errbuf, - "Couldn't find figure file %s with CMS name %s; continuing.\nNote that an absolute path or a relative path with .. are denied in -R2 mode.", s, trunc_s); + "Couldn't find figure file %s with CMS name %s; continuing.", s, trunc_s); + if (secure == 2) { + strcat(errbuf, "\nNote that an absolute path or a relative path with .. are denied in -R2 mode."); + } #else /* VMCMS */ sprintf(errbuf, - "Couldn't find figure file %s with MVS name %s; continuing.\nNote that an absolute path or a relative path with .. are denied in -R2 mode.", s, trunc_s); + "Couldn't find figure file %s with MVS name %s; continuing.", s, trunc_s); + if (secure == 2) { + strcat(errbuf, "\nNote that an absolute path or a relative path with .. are denied in -R2 mode."); + } #endif /* VMCMS */ #else /* VMCMS || MVSXA */ - sprintf(errbuf, "Could not find figure file %s; continuing.\nNote that an absolute path or a relative path with .. are denied in -R2 mode.", s); + sprintf(errbuf, "Could not find figure file %s; continuing.", s); + if (secure == 2) { + strcat(errbuf, "\nNote that an absolute path or a relative path with .. are denied in -R2 mode."); + } #endif /* VMCMS || MVSXA */ break; #ifndef VMCMS @@ -174,7 +183,10 @@ copyfile_general(const char *s, struct header_list *cur_header) if(f==NULL) f = search(figpath, s, READBIN); } - sprintf(errbuf, "! Could not find header file %s.\nNote that an absolute path or a relative path with .. are denied in -R2 mode.", s); + sprintf(errbuf, "! Could not find header file %s.", s); + if (secure == 2) { + strcat(errbuf, "\nNote that an absolute path or a relative path with .. are denied in -R2 mode."); + } break; } if (f==NULL) |