Issue #2791 has been updated by vadaszi.

Status changed from New to In Progress

It would be nice, if the default values for row and col wouldn't be duplicated 
by this change.
The errno variable should be explicitly set to 0 before calling strtol, when 
you want to check errno != 0 afterwards.
Also we it would make sense to fallback to default values when negative values 
are given for COLUMNS or LINES.

Note that there are a few other places which call getenv("LINES") or 
getenv("COLUMNS") throughout nvi, which .
As an alternative instead of silently falling back to default values, it might 
make sense to abort vi with an error message, if we would crash anyway 
afterwards.

Note that there is an active upstream project for DragonFly's vi: 
<https://github.com/lichray/nvi2>, which might be a better place to submit and 
discuss this change.

----------------------------------------
Submit #2791: Float exception with vi
http://bugs.dragonflybsd.org/issues/2791#change-12663

* Author: dclink
* Status: In Progress
* Priority: Low
* Assignee: 
* Category: 
* Target version: 
----------------------------------------
How to reproduce :
- set COLUMNS or LINES env var with unexpected values.
Proposed fix :
- Fallback to default values in those cases.

---Files--------------------------------
patch-nvi.txt (965 Bytes)


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://bugs.dragonflybsd.org/my/account

Reply via email to