Re: [PATCH libdrm 1/1] tests/exynos: Fix warnings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Jan Vesely wrote:
>> 
>>> @@ -573,6 +573,7 @@ static int g2d_checkerboard_test(struct
>>> exynos_device *dev, src_img.user_ptr[0].userptr = (unsigned
>>> long)checkerboard; src_img.user_ptr[0].size = img_w * img_h *
>>> 4; break; +	case G2D_IMGBUF_COLOR: default: ret = -EFAULT; goto
>>> fail;
>>> 
>> Hmm, I don't see the reason why this label should be added to the
>> switch statement?
> 
> This is mostly to appease the compiler. -Wswitch-enum warns about 
> missing enumeration cases even if default is present. On the other
> hand it also warns against branches that use values outside of the 
> enumeration (which might be useful).
Ah, that makes sense. I guess adding the label is a good thing then!

With best wishes,
Tobias

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAlUJ3UYACgkQ6bCODwikBXd6xgCdG4sZERoY6KalhPn6AhyoxfbO
8EQAnRrCZrPXN/fjqwZT4X6a/7wLofeJ
=C/FO
-----END PGP SIGNATURE-----
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel





[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux