Segfault in SDL_ConvertSurface() for certain formats in SDL2

Hi,

find attached a small test program for a surface conversion from
SDL_PIXELFORMAT_RGB444 to SDL_PIXELFORMAT_RGB332, which causes a crash
in the DUFFS_LOOP() macro. The same issue also occurs for the conversion
to SDL_PIXELFORMAT_ARGB2101010.
I did not check on other source pixel formats so far.

The issue can be reproduced for at least rev. 6302 to 6305.

gdb backtrace:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 800e041c0 (LWP 100441/initial thread)]
0x00000008006d9017 in Blit1to2 (info=0x800e2fd20)
at …/src/video/SDL_blit_1.c:103
103 DUFFS_LOOP(
(gdb) bt
#0 0x00000008006d9017 in Blit1to2 (info=0x800e2fd20)
at …/src/video/SDL_blit_1.c:103
#1 0x00000008006d7146 in SDL_SoftBlit (src=0x800f2e5e0,
srcrect=0x7fffffffe6c0, dst=0x800f2e580, dstrect=0x7fffffffe6c0)
at …/src/video/SDL_blit.c:88
#2 0x000000080072079f in SDL_LowerBlit (src=0x800f2e5e0,
srcrect=0x7fffffffe6c0, dst=0x800f2e580, dstrect=0x7fffffffe6c0)
at …/src/video/SDL_surface.c:494
#3 0x0000000800721116 in SDL_ConvertSurface (surface=0x800f2e5e0,
format=0x800ef0900, flags=0) at …/src/video/SDL_surface.c:811
#4 0x00000000004009b4 in main (argc=1, argv=0x7fffffffe7a8) at main.c:35
-------------- next part --------------
A non-text attachment was scrubbed…
Name: main.c
Type: text/x-csrc
Size: 940 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20120416/fd7bc09b/attachment.c
-------------- next part --------------
A non-text attachment was scrubbed…
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20120416/fd7bc09b/attachment.pgp