diff options
author | Chris Liddell <chris.liddell@artifex.com> | 2015-08-24 17:38:15 +0100 |
---|---|---|
committer | Chris Liddell <chris.liddell@artifex.com> | 2015-08-25 09:10:57 +0100 |
commit | 8fcea1fef23c45a81ad5d13a5e3afd5662e0efef (patch) | |
tree | 7149c397dfa1e571c799d67bf66e5c3a2183da27 /base/gsiorom.c | |
parent | a32ece5ee924a6a4a581f7e6dd298f9d9af6d475 (diff) | |
download | ghostpdl-8fcea1fef23c45a81ad5d13a5e3afd5662e0efef.tar.gz |
Bug 696126 (2): PCL/XPS should (sort of) ignore COMPILE_INITS (for now)
As the PCL and XPS exes *must* have the icc profiles available in a romfs, they
will paretially ignore the COMPILE_INITS setting, and always use a rom file
system for the ICC profiles. COMPILE_INITS=0 will cause PCL to not include
it's fonts in the romfs.
This means always including the romfs I/O code in the graphics library, then
building an empty romfs into Ghostscript for COMPILE_INITS=0, and the romfs i/o
will now return gs_error_unregistered from its file_status method if
the empty romfs is found (identified by gs_romfs_buildtime being zero).
No cluster differences.
Diffstat (limited to 'base/gsiorom.c')
-rw-r--r-- | base/gsiorom.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/base/gsiorom.c b/base/gsiorom.c index ca4a90cbe..1f15593c8 100644 --- a/base/gsiorom.c +++ b/base/gsiorom.c @@ -308,6 +308,14 @@ romfs_file_status(gx_io_device * iodev, const char *fname, struct stat *pstat) char *filename; uint namelen = strlen(fname); + /* a build time of zero indicates we have the "dummy" romfs + * used when COMPILE_INITS==0 - returning a specific error here + * gives us a quick way to check for that. + */ + if (gs_romfs_buildtime == (time_t)0) { + return_error(gs_error_unregistered); + } + memset(pstat, 0, sizeof(struct stat)); /* scan the inodes to find the requested file */ for (i=0; node_scan != 0; i++, node_scan = gs_romfs[i]) { |