DivelogImportDialog

Dirk Hohndel dirk at hohndel.org
Sat Sep 24 08:38:16 PDT 2016


Miika,

Can you take a look at the DivelogImportDialog for me? This code worries
me:

int DiveLogImportDialog::parseTxtHeader(QString fileName, char **params, int pnr)
{
	QFile f(fileNames.first());

(and fileName is unused in the function)

The only two call sites of parseTxtHeader look like this:

	pnr = parseTxtHeader(fileNames[i], params, pnr);

So the caller seems to think that the parseTxtHeader function will use
item number 'i' in the array of fileNames, but instead the function
ignores the parameter and always uses the first entry.

git blame tells me that you wrote this :-)

Thanks

/D



More information about the subsurface mailing list