mirror of
https://github.com/cmclark00/retro-imager.git
synced 2025-05-18 16:05:21 +01:00
Do not use libcurl for reading local files
We originally used libcurl for both downloading images from Internet and reading local files to have the same code path for both. It doesn't work that well in practice, as Qt and libcurl are not on the same page how special characters such as Chinese characters are represented in a local file URL. So create a new class to handle local files. Closes #76
This commit is contained in:
parent
123542a66b
commit
fa7637e7dc
6 changed files with 115 additions and 8 deletions
|
@ -48,13 +48,13 @@ protected:
|
|||
|
||||
QByteArray _popQueue();
|
||||
void _pushQueue(const char *data, size_t len);
|
||||
void _cancelExtract();
|
||||
virtual void _cancelExtract();
|
||||
virtual size_t _writeData(const char *buf, size_t len);
|
||||
virtual void _onDownloadSuccess();
|
||||
virtual void _onDownloadError(const QString &msg);
|
||||
|
||||
ssize_t _on_read(struct archive *a, const void **buff);
|
||||
int _on_close(struct archive *a);
|
||||
virtual ssize_t _on_read(struct archive *a, const void **buff);
|
||||
virtual int _on_close(struct archive *a);
|
||||
|
||||
static ssize_t _archive_read(struct archive *a, void *client_data, const void **buff);
|
||||
static int _archive_close(struct archive *a, void *client_data);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue