Bug 333860 - fileexporterris.cpp:173: possible cut'n'paste error ?
Summary: fileexporterris.cpp:173: possible cut'n'paste error ?
Status: RESOLVED FIXED
Alias: None
Product: KBibTeX
Classification: Applications
Component: Loading/saving files (show other bugs)
Version: 0.5
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: Thomas Fischer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-25 10:13 UTC by dcb314
Modified: 2014-04-26 18:57 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 dcb314 2014-04-25 10:13:39 UTC
kbibtex-0.5/src/libkbibtexio/fileexporterris.cpp:173]: (style) Expression is always false because 'else if' condition matches previous condition at line 153.

        else if (key == Entry::ftDOI)
            result &= writeKeyValue(stream, "DO", PlainTextValue::text(value, bibtexfile));
        ...
        } else if (key == Entry::ftDOI)
            result &= writeKeyValue(stream, "UR", PlainTextValue::text(value, bibtexfile));
Comment 1 Thomas Fischer 2014-04-26 18:45:18 UTC
Git commit 8fb73ed64da07461028b18657a446f51d7b54909 by Thomas Fischer.
Committed on 26/04/2014 at 18:41.
Pushed by thomasfischer into branch 'master'.

Removing duplicate "else if" clauses on DOI value

As reported in KDE bug 333860, the RIS exporter has two "else if"
clauses to handle DOI values. The second clause is never used in the
program flow and can be removed.

M  +0    -2    src/io/fileexporterris.cpp

http://commits.kde.org/kbibtex/8fb73ed64da07461028b18657a446f51d7b54909
Comment 2 Thomas Fischer 2014-04-26 18:55:52 UTC
Git commit 560493c0911d38eb373c7cab03a4140ed448c4b5 by Thomas Fischer.
Committed on 26/04/2014 at 18:41.
Pushed by thomasfischer into branch 'kbibtex/0.5'.

Removing duplicate "else if" clauses on DOI value

As reported in KDE bug 333860, the RIS exporter has two "else if"
clauses to handle DOI values. The second clause is never used in the
program flow and can be removed.

M  +0    -2    src/libkbibtexio/fileexporterris.cpp

http://commits.kde.org/kbibtex/560493c0911d38eb373c7cab03a4140ed448c4b5
Comment 3 Thomas Fischer 2014-04-26 18:57:47 UTC
Should be fixed by now. The commit messages in the previous comments to this bug had commits that included a compilation bug. Should be fixed as of f2f296e for master and 9b0bc01 for branch kbibtex/0.5.