diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2007-03-11 22:08:57 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2007-03-11 22:08:57 +0000 |
commit | 9cf51227979c84a9ed74c339290c3f65f0d58c4f (patch) | |
tree | a0c2a9fd6b328eca1dfbdf17989b5ef175427124 /image | |
parent | 58c217cbeeca8bac6c5edd3d156b1f5bbefed3d3 (diff) | |
download | netsurf-9cf51227979c84a9ed74c339290c3f65f0d58c4f.tar.gz netsurf-9cf51227979c84a9ed74c339290c3f65f0d58c4f.tar.bz2 |
Content handlers should not call warn_user - they should broadcast the
error using content_broadcast and leave it to the content owner(s) to
decide what to do about it.
Only use warn_user for top-level contents.
svn path=/trunk/netsurf/; revision=3204
Diffstat (limited to 'image')
-rw-r--r-- | image/bmp.c | 2 | ||||
-rw-r--r-- | image/gif.c | 2 | ||||
-rw-r--r-- | image/ico.c | 2 | ||||
-rw-r--r-- | image/jpeg.c | 1 |
4 files changed, 0 insertions, 7 deletions
diff --git a/image/bmp.c b/image/bmp.c index c58bc044f..204dcaf9c 100644 --- a/image/bmp.c +++ b/image/bmp.c @@ -28,7 +28,6 @@ bool nsbmp_create(struct content *c, const char *params[]) { if (!c->data.bmp.bmp) { msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; } return true; @@ -53,7 +52,6 @@ bool nsbmp_convert(struct content *c, int iwidth, int iheight) { case BMP_INSUFFICIENT_MEMORY: msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; case BMP_INSUFFICIENT_DATA: case BMP_DATA_ERROR: diff --git a/image/gif.c b/image/gif.c index 02148f264..a3e0b00af 100644 --- a/image/gif.c +++ b/image/gif.c @@ -48,7 +48,6 @@ bool nsgif_create(struct content *c, const char *params[]) { if (!c->data.gif.gif) { msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; } return true; @@ -74,7 +73,6 @@ bool nsgif_convert(struct content *c, int iwidth, int iheight) { case GIF_INSUFFICIENT_MEMORY: msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; case GIF_INSUFFICIENT_DATA: case GIF_DATA_ERROR: diff --git a/image/ico.c b/image/ico.c index 546727595..fbf6405d5 100644 --- a/image/ico.c +++ b/image/ico.c @@ -28,7 +28,6 @@ bool nsico_create(struct content *c, const char *params[]) { if (!c->data.ico.ico) { msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; } return true; @@ -54,7 +53,6 @@ bool nsico_convert(struct content *c, int iwidth, int iheight) { case BMP_INSUFFICIENT_MEMORY: msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; case BMP_INSUFFICIENT_DATA: case BMP_DATA_ERROR: diff --git a/image/jpeg.c b/image/jpeg.c index 87d251bac..e18d2b0a3 100644 --- a/image/jpeg.c +++ b/image/jpeg.c @@ -104,7 +104,6 @@ bool nsjpeg_convert(struct content *c, int w, int h) msg_data.error = messages_get("NoMemory"); content_broadcast(c, CONTENT_MSG_ERROR, msg_data); - warn_user("NoMemory", 0); return false; } |