bugGNU Octave - Bugs: bug #50874, [octave forge] (image) bwdist call...


bug #50874: [octave forge] (image) bwdist call causes application crash

Submitted by:  None
Submitted on:  Tue 25 Apr 2017 01:38:13 PM UTC  
Category: Octave Forge PackageSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Segfault, Bus Error, etc.
Status: Need InfoAssigned to: None
Originator Name: Erwin NindlOriginator Email: -unavailable-
Open/Closed: OpenRelease: 4.2.1
Operating System: Microsoft Windows

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Thu 04 May 2017 10:37:02 AM UTC, comment #5:

I run the command

bwdist ([1 0]);

Avinoam Kalma <avinoam>
Project Member
Thu 04 May 2017 10:33:46 AM UTC, comment #4:

Checking again, I have found that the crash is in line 330,
disty[i]=newdisty, because i=-1.
From some reason, in line 329 distx[i]=newdistx does not crash.

i=-1 already in line 321
olddist2 = (*func)(distx[i], disty[i]);
So olddist2 is actually garbage.

Avinoam Kalma <avinoam>
Project Member
Tue 02 May 2017 06:23:51 PM UTC, comment #3:

I could reproduce this crash in Windows, 4.2.1 and 4.3.0+.
In 4.0.2 there is no crash.

I have tried to add some prints in order to locate the reason
to the crash.

Carnë: Could you please upload here a version with printouts, so we could compare the Linux results with the Windows results, and may be it will give you a hint to the bug solution?

Avinoam Kalma <avinoam>
Project Member
Tue 02 May 2017 04:48:30 PM UTC, comment #2:

Works for me on Linux (Debian Jessie). I have tried Octave 4.0.0, 4.2.1, and 4.3.0+ against the last image package release and the last image development head.

If the problems only happens on Windows, I won't be able to reproduce it. I would still welcome any patch though. Or can anyone give me more details for reproducing it on Linux?

Carnë Draug <carandraug>
Project Member
Sun 30 Apr 2017 06:32:32 PM UTC, comment #1:

Adding package maintainer to CC.

Avinoam Kalma <avinoam>
Project Member
Tue 25 Apr 2017 01:38:13 PM UTC, original submission:

A call to bwdist fails on Win7 amd64.
It works correctly with Octave v4.0.3.

GNU Octave Shell:

GNU Octave, version 4.2.1
Copyright (C) 2017 John W. Eaton and others.
This is free software; see the source code for copying conditions.
FITNESS FOR A PARTICULAR PURPOSE. For details, type 'warranty'.

Octave was configured for "x86_64-w64-mingw32".

Additional information about Octave is available at http://www.octave.org.

Please contribute if you find this software useful.
For more information, visit http://www.octave.org/get-involved.html

Read http://www.octave.org/bugs.html to learn how to submit bug reports.
For information about changes from previous versions, type 'news'.

octave:1> pkg load image
octave:2> foo = [1, 1, 1, 1, 0, 0, 0];
octave:3> bar = bwdist(foo);



(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):

Attached Files
file #40501:  gnu-octave-bug.png added by None (81KiB - image/png)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by jwe (Updated the item)
  • -unavailable- added by avinoam (Posted a comment)
  • -unavailable- added by avinoam
  • -unavailable- added by None (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 6 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 12 Aug 2017 07:01:23 PM UTCjweSummarybwdist call causes application crash=>[octave forge] (image) bwdist call causes application crash
    Tue 02 May 2017 04:48:30 PM UTCcarandraugStatusConfirmed=>Need Info
    Sun 30 Apr 2017 06:34:41 PM UTCavinoamCategoryOctave Function=>Octave Forge Package
    Sun 30 Apr 2017 06:32:32 PM UTCavinoamStatusNone=>Confirmed
      Carbon-Copy-=>Added -unavailable-
    Tue 25 Apr 2017 01:38:13 PM UTCNoneAttached File-=>Added gnu-octave-bug.png, #40501

    Back to the top

    Powered by Savane 3.1-cleanup1