[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-patch-tracker] [patch #9101] shapewrite (mapping package): bugfi
From: |
Martin Kunz |
Subject: |
[Octave-patch-tracker] [patch #9101] shapewrite (mapping package): bugfixes and test |
Date: |
Sat, 27 Aug 2016 06:15:15 +0000 (UTC) |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; WOW64; rv:48.0) Gecko/20100101 Firefox/48.0 |
URL:
<http://savannah.gnu.org/patch/?9101>
Summary: shapewrite (mapping package): bugfixes and test
Project: GNU Octave
Submitted by: mkunz
Submitted on: Sat 27 Aug 2016 06:15:13 AM GMT
Category: Forge : other
Priority: 5 - Normal
Status: None
Privacy: Public
Assigned to: None
Originator Email:
Open/Closed: Open
Discussion Lock: Any
_______________________________________________________
Details:
Hi Philip,
I have recently stumbled upon some bugs in shapewrite and would like to share
my fixes. I attach a diff against the version distributed within mapping
1.2.1.
The first bug was with file handling: When a full path is supplied, fileparts
returns the directory without trailing separator. During the creation of bname
by concatenation this lead to a wrong path and filename.
The second one was with point data that had no bounding box defined. There was
a section in the code that seemed to be supposed to handle this situation
(creation of a dummy bounding box), but it did not work. My proposed fix
creates a bounding box from the highest/lowest coordinate of all points. Is
that a problem, i.e. are there cases where a bounding box that extents beyond
the boxes would be useful?
Furthermore I have added two tests. They succeed, but the last assert
demonstrates that a some space padding happens to string attributes the reason
of which I do not no.
I should also add that I have little knowledge about shapefiles. O:-)
Cheers,
Martin
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: Sat 27 Aug 2016 06:15:13 AM GMT Name: shapereadDiff.txt Size: 3kB
By: mkunz
<http://savannah.gnu.org/patch/download.php?file_id=38371>
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/patch/?9101>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-patch-tracker] [patch #9101] shapewrite (mapping package): bugfixes and test,
Martin Kunz <=