octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #59942] Warning about Jasper library after usi


From: Rik
Subject: [Octave-bug-tracker] [bug #59942] Warning about Jasper library after using graphics
Date: Mon, 25 Jan 2021 19:06:03 -0500 (EST)
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.66 Safari/537.36

Update of bug #59942 (project octave):

                  Status:                    None => Need Info              

    _______________________________________________________

Follow-up Comment #1:

Octave, as you found, does not use Jasper directly.  One possibility is that
this is coming through a dependence on GraphicsMagick.  Did the code you ran
involve a lot of image processing?

This is going to be pretty difficult to debug, and is probably an upstream
upstream bug rather than one in Octave.  If you could localize it in some way
to some code that we might be able to test that would be helpful.

Downloading the source code, I find that there is only one place where this
warning occurs.


/*
NOTE:
The version of the function jas_stream_memopen only exists for backwards
compatibility.
Eventually, it should be replaced by jas_stream_memopen2.
In retrospect, it was a very poor choice to have specified the buffer
size parameter (bufsize) to have type int.  On some machines, int may only
be a 16-bit integer.  This precludes larger-sized buffer allocations, which
are needed in practice.

If bufsize <= 0, the buffer is growable; otherwise, the buffer has a fixed
size of bufsize.
If buf is 0, the buffer is dynamically allocated with jas_malloc.
If buf is not 0 and bufsize <= 0 (which is not permitted in any
circumstances), bad things will happen (especially if the buf was not
allocated with jas_malloc).
*/
jas_stream_t *jas_stream_memopen(char *buf, int bufsize)
{
        char *new_buf;
        size_t new_bufsize;

        JAS_DBGLOG(100, ("jas_stream_memopen(%p, %d)\n", buf, bufsize));
        if (bufsize < 0) {
                jas_deprecated("negative buffer size for jas_stream_memopen");
        }


This definitely looks like some other library's problem, rather than Octave's,
who is calling jas_stream_memopen rather than jas_stream_memopen2.

What operating system and version are you running?  Is it particularly old or
new?

    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?59942>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]