[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-games-devel
Subject:    Re: Catastrophic failure in KSudoku
From:       Ian Wadham <iandw.au () gmail ! com>
Date:       2019-03-20 0:32:17
Message-ID: 746825FC-3816-4312-BB7B-534E439B4992 () gmail ! com
[Download RAW message or body]


> On 20 Mar 2019, at 3:36 am, Jeremy Whiting <jpwhiting@kde.org> wrote:
> 
> I'm not sure why gmail's reply to all isn't putting you in Ian…

No worries. I am still on the kde-games-devel list… :-)

> Anyway, the cause is the QDomDocument::setContent from the QTemporaryFile after it \
> copies the file out of the installation path (why is that needed by the way?)

I have never dared touch those lines of code, because I know almost nothing about \
KIO.

However, I think the intention of the original author, back in 2007-8, was that \
"custom" game files could come from the Internet, maybe Hot New Stuff, as well as \
being locally installed. So maybe copying a read-only file to a temp file guarded \
against broken network connections, which happened quite often in those days.

Realistically, the structure of a "custom" KSudoku file has never been properly \
documented, so nobody has ever contributed a new one AFAIK. But I have added custom \
game types from time to time, by request from users via the kde-games-devel list or \
bugzilla.

> Adding some debugging to the call it seems the error is "Unexpected end of file" on \
> line 1 column 1. I checked the file does exist and such, I wonder if the download \
> copy job is leaving the QTemporaryFile object's seek point at the end of the file \
> as it writes it or something. No, adding a tmpFile.reset() before setting the \
> content does not help. It's as if the copy job finishes before the file is written \
> to disk. I don't have any weird mount options (or any, since /tmp/ is just part of \
> my / partition here). Not sure what's going on to cause QDomDocument::setContent to \
> think the file is empty…

Cheers, Ian W.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic