added missing returns after slang_info_log_error() calls
authorBrian <brian@yutani.localnet.net>
Wed, 28 Mar 2007 18:48:27 +0000 (12:48 -0600)
committerBrian <brian@yutani.localnet.net>
Wed, 28 Mar 2007 18:48:27 +0000 (12:48 -0600)
src/mesa/shader/slang/slang_codegen.c

index bd403b7c30cdd57a3a0a4e2178665fee2dcd0518..22bcfe67d4caa76f91fd736e18753b32e02e41c9 100644 (file)
@@ -2450,11 +2450,13 @@ _slang_gen_operation(slang_assemble_ctx * A, slang_operation *oper)
    case SLANG_OPER_BREAK:
       if (!A->CurLoop) {
          slang_info_log_error(A->log, "'break' not in loop");
+         return NULL;
       }
       return new_break(A->CurLoop);
    case SLANG_OPER_CONTINUE:
       if (!A->CurLoop) {
          slang_info_log_error(A->log, "'continue' not in loop");
+         return NULL;
       }
       return _slang_gen_continue(A, oper);
    case SLANG_OPER_DISCARD: