Re: Ghostrscript/GhostPDL 9.18 Release Candidate 1

Johannes Meixner <[email protected]>
Newsgroups gmane.comp.printing.ghostscript.devel
Message-ID <[email protected]>
Hello,

On Sep 24 11:32 Johannes Meixner wrote (excerpt):
> I had a look at base/gximono.c but for me it is not obvious
> what is actually meant with
>  dev_value = color_cache[*psrc * spp_out];
>
> dev_value is a pointer to byte and I do not understand
> the idea behind how that pointer value is calculated
> so that currently I cannot provide a reasonable patch.

Instead of trying to understand that functionality
in gximono.c I had a better idea and made a diff
between gximono.c in Ghostscript 9.16 versus now
in 9.18rc1 which shows the following:

In Ghostscript 9.16 it was:
  dev_value = color_cache + psrc[dda_ht.state.Q] * spp_out;

In Ghostscript 9.18rc1 it is:
   dev_value = color_cache[*psrc * spp_out];

Because color_cache is also a pointer (to byte)
"color_cache + <something>" results a pointer
so that I assume the following is the right fix:

In Ghostscript 9.18rc1 in gximono.c I replaced all
   dev_value = color_cache[*psrc * spp_out];
with
   dev_value = &(color_cache[*psrc * spp_out]);
so that the pointer and not the value gets assigned.


Kind Regards
Johannes Meixner
-- 
SUSE LINUX GmbH - GF: Felix Imendoerffer, Jane Smithard,
Graham Norton - HRB 21284 (AG Nuernberg)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.