Bug 310794 - CSV Plugin- Crash if memoColumn value in a saved profile does not match the file to be imported.
Summary: CSV Plugin- Crash if memoColumn value in a saved profile does not match the f...
Status: RESOLVED FIXED
Alias: None
Product: kmymoney
Classification: Applications
Component: general (show other bugs)
Version: git (master)
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: KMyMoney Devel Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-28 00:27 UTC by allan
Modified: 2012-12-04 20:59 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description allan 2012-11-28 00:27:15 UTC
A bank may change the format of its statement file.  If a file which is being loaded has fewer columns than the file whose values were saved in the profile, and if the saved memocolumn value is out of bounds for the present file, the plugin will crash.
Other column settings are loaded into their comboboxes, and out of bounds values are not accepted.  As the memocolumn can have more than one value, the profile values are loaded into a QStringList();

Reproducible: Always

Steps to Reproduce:
1. Load a CSV file using a profile which was produced by a newer statement format with more columns.
2. If the memocolumn in the profile is set to capture the account balance, which tends to be the last column, that column value may not be present in an earlier version of the statement for the same account.
3. Attempt to load that file via the CSV plugin.
Actual Results:  
Crash.

Expected Results:  
No crash.  Out of bounds settings should not be accepted.
Comment 1 allan 2012-12-04 20:59:59 UTC
Git commit 4bd568a458b8909d501177771a4a5094c86455cc by Allan Anderson.
Committed on 04/12/2012 at 21:52.
Pushed by allananderson into branch 'master'.
the file to be imported.

M  +4    -2    kmymoney/plugins/csvimport/csvdialog.cpp

http://commits.kde.org/kmymoney/4bd568a458b8909d501177771a4a5094c86455cc