Skip to content

Commit

Permalink
Use unrollType for non-pointer global struct vars
Browse files Browse the repository at this point in the history
  • Loading branch information
mrstanb committed Nov 19, 2023
1 parent 80492cc commit f2ca6d1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/analyses/memLeak.ml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,11 @@ struct

let get_global_struct_non_ptr_vars () =
get_global_vars ()
|> List.filter (fun v -> match v.vtype with TComp (_, _) | (TNamed ({ttype = TComp _; _}, _)) -> true | _ -> false)
|> List.filter (fun v ->
match unrollType v.vtype with
| TComp (_, _)
| (TNamed ({ttype = TComp _; _}, _)) -> true
| _ -> false)

let get_reachable_mem_from_globals (global_vars:varinfo list) ctx =
global_vars
Expand Down

0 comments on commit f2ca6d1

Please sign in to comment.