diff options
| author | Simon Rettberg | 2026-01-28 12:53:53 +0100 |
|---|---|---|
| committer | Simon Rettberg | 2026-01-28 12:53:53 +0100 |
| commit | 8e82785c584dc13e20f9229decb95bd17bbe9cd1 (patch) | |
| tree | a8b359e59196be5b2e3862bed189107f4bc9975f /src/tests/pixbuf_test.c | |
| parent | Merge branch 'master' into openslx (diff) | |
| parent | [prefix] Make unlzma.S compatible with 386 class CPUs (diff) | |
| download | ipxe-openslx.tar.gz ipxe-openslx.tar.xz ipxe-openslx.zip | |
Merge branch 'master' into openslxopenslx
Diffstat (limited to 'src/tests/pixbuf_test.c')
| -rw-r--r-- | src/tests/pixbuf_test.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/tests/pixbuf_test.c b/src/tests/pixbuf_test.c index aaa516bb2..cbc3a7617 100644 --- a/src/tests/pixbuf_test.c +++ b/src/tests/pixbuf_test.c @@ -32,6 +32,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL ); /* Forcibly enable assertions */ #undef NDEBUG +#include <string.h> #include <assert.h> #include <ipxe/image.h> #include <ipxe/pixbuf.h> @@ -54,9 +55,6 @@ void pixbuf_okx ( struct pixel_buffer_test *test, const char *file, assert ( ( test->width * test->height * sizeof ( test->data[0] ) ) == test->len ); - /* Correct image data pointer */ - test->image->data = virt_to_user ( ( void * ) test->image->data ); - /* Check that image is detected as correct type */ okx ( register_image ( test->image ) == 0, file, line ); okx ( test->image->type == test->type, file, line ); @@ -71,9 +69,8 @@ void pixbuf_okx ( struct pixel_buffer_test *test, const char *file, /* Check pixel buffer data */ okx ( pixbuf->len == test->len, file, line ); - okx ( memcmp_user ( pixbuf->data, 0, - virt_to_user ( test->data ), 0, - test->len ) == 0, file, line ); + okx ( memcmp ( pixbuf->data, test->data, test->len ) == 0, + file, line ); pixbuf_put ( pixbuf ); } |
