diff options
author | Alon Levy <alevy@redhat.com> | 2012-01-31 00:23:09 +0200 |
---|---|---|
committer | Alon Levy <alevy@redhat.com> | 2012-01-31 00:23:09 +0200 |
commit | d07c8acc3057cc577a67d04dc8499e2996ed30b4 (patch) | |
tree | fedd2aba75a5e1ad4d3035d5424679c48ae4511c | |
parent | da1d595ad303b997343df91ebfb70c82c4bbb748 (diff) |
qxl_image: cleanup qxl_image_create
-rw-r--r-- | src/qxl_image.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/qxl_image.c b/src/qxl_image.c index f1916f1..aceac1e 100644 --- a/src/qxl_image.c +++ b/src/qxl_image.c @@ -129,24 +129,22 @@ qxl_image_create (qxl_screen_t *qxl, const uint8_t *data, int x, int y, int width, int height, int stride, int Bpp, Bool fallback) { - unsigned int hash; - image_info_t *info; - - data += y * stride + x * Bpp; - - { + unsigned int hash; + image_info_t *info; struct QXLImage *image; struct QXLDataChunk *head; struct QXLDataChunk *tail; int dest_stride = width * Bpp; int h; + data += y * stride + x * Bpp; + #if 0 ErrorF ("Must create new image of size %d %d\n", width, height); #endif /* Chunk */ - + /* FIXME: Check integer overflow */ head = tail = NULL; @@ -241,7 +239,6 @@ qxl_image_create (qxl_screen_t *qxl, const uint8_t *data, } return image; - } } void |