summaryrefslogtreecommitdiff
path: root/atari/download.c
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2016-04-20 10:43:58 +0100
committerVincent Sanders <vince@kyllikki.org>2016-04-20 10:43:58 +0100
commit3930d00519bbcee968a804b1f445c1638531cc15 (patch)
tree33ff87e76dd6f95d0e4eba80019149bbe59a6001 /atari/download.c
parent759c34b32447417faeec20513a0e586230f246cd (diff)
downloadnetsurf-3930d00519bbcee968a804b1f445c1638531cc15.tar.gz
netsurf-3930d00519bbcee968a804b1f445c1638531cc15.tar.bz2
atari header cleanup and warning squash
This rationalises atari platform user of headers and squashes a lot of warnings. Should not be viewed as real maintenance, more that it was getting in the way of fixing real core header issues.
Diffstat (limited to 'atari/download.c')
-rw-r--r--atari/download.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/atari/download.c b/atari/download.c
index ce56d66d3..c6f1d684b 100644
--- a/atari/download.c
+++ b/atari/download.c
@@ -195,9 +195,8 @@ static void on_close(struct gui_download_window * dw)
static void gui_download_window_destroy( struct gui_download_window * gdw)
{
+ LOG("gdw %p", gdw);
-
- LOG("");
if (gdw->status == NSATARI_DOWNLOAD_WORKING) {
download_context_abort(gdw->ctx);
}
@@ -355,14 +354,13 @@ gui_download_window_create(download_context *ctx, struct gui_window *parent)
static nserror gui_download_window_data(struct gui_download_window *dw,
const char *data, unsigned int size)
{
-
uint32_t clck = clock();
uint32_t tnow = clck / (CLOCKS_PER_SEC>>3);
uint32_t sdiff = (clck / (CLOCKS_PER_SEC)) - dw->start;
- LOG("");
+ LOG("dw %p",dw);
- if(dw->abort == true){
+ if (dw->abort == true){
dw->status = NSATARI_DOWNLOAD_CANCELED;
dw->abort = false;
download_context_abort(dw->ctx);
@@ -409,6 +407,7 @@ static void gui_download_window_error(struct gui_download_window *dw,
const char *error_msg)
{
LOG("%s", error_msg);
+
strncpy((char*)&dw->lbl_file, error_msg, MAX_SLEN_LBL_FILE-1);
dw->status = NSATARI_DOWNLOAD_ERROR;
gemtk_wm_exec_redraw(dw->guiwin, NULL);
@@ -418,7 +417,7 @@ static void gui_download_window_error(struct gui_download_window *dw,
static void gui_download_window_done(struct gui_download_window *dw)
{
- LOG("");
+ LOG("dw %p", dw);
// TODO: change abort to close
dw->status = NSATARI_DOWNLOAD_COMPLETE;