Skip to content

Commit 970abfe

Browse files
committed
Don't catch exception which is not supposed to get raised
1 parent 47c9084 commit 970abfe

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/cdomain/value/cdomains/valueDomain.ml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1102,8 +1102,7 @@ struct
11021102
begin
11031103
match fld.ftype with (* TODO: unrolltype? *)
11041104
| TArray(_, l, _) ->
1105-
let len = try Cil.lenOfArray l
1106-
with Cil.LenOfArray -> 42 (* will not happen, VLA not allowed in union and struct *) in
1105+
let len = Cil.lenOfArray l in (* LenOfArray exception will not happen, VLA not allowed in union and struct *)
11071106
Array(CArrays.make (IndexDomain.of_int (Cilfacade.ptrdiff_ikind ()) (Z.of_int len)) Top), offs
11081107
| _ -> top (), offs (* will not happen*)
11091108
end

0 commit comments

Comments
 (0)