nouveau: honor fread return value in the nouveau_compiler
authorEmil Velikov <emil.l.velikov@gmail.com>
Wed, 12 Mar 2014 16:58:26 +0000 (16:58 +0000)
committerEmil Velikov <emil.l.velikov@gmail.com>
Fri, 14 Mar 2014 13:00:01 +0000 (13:00 +0000)
commitad4a44ebfc9f72d34bf3523e455822896a788507
treebf5be5392f93a6f75a291043967f97371f4e4d63
parentae7d2361721926dc16a4c71034536f6b8676e1be
nouveau: honor fread return value in the nouveau_compiler

There is little point of continuing if fread returns zero, as it
indicates that either the file is empty or cannot be read from.
Bail out if fread returns zero after closing the file.

Cc: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
src/gallium/drivers/nouveau/nouveau_compiler.c