Print this page
12724 update smatch to 0.6.1-rc1-il-5

Split Close
Expand all
Collapse all
          --- old/usr/src/tools/smatch/src/smatch_real_absolute.c
          +++ new/usr/src/tools/smatch/src/smatch_real_absolute.c
↓ open down ↓ 28 lines elided ↑ open up ↑
  29   29   * than nothing and that will help eliminate some false positives.
  30   30   *
  31   31   */
  32   32  
  33   33  #include "smatch.h"
  34   34  #include "smatch_slist.h"
  35   35  #include "smatch_extra.h"
  36   36  
  37   37  static int my_id;
  38   38  
       39 +void set_real_absolute(struct expression *expr, struct smatch_state *state)
       40 +{
       41 +        set_state_expr(my_id, expr, clone_estate(state));
       42 +}
       43 +
  39   44  static void extra_mod_hook(const char *name, struct symbol *sym, struct expression *expr, struct smatch_state *state)
  40   45  {
  41   46          struct smatch_state *abs;
  42   47          struct range_list *rl;
  43   48  
  44   49          abs = get_state(my_id, name, sym);
  45   50          if (!abs || !estate_rl(abs))
  46   51                  return;
  47   52          rl = rl_intersection(estate_rl(abs), estate_rl(state));
  48   53          set_state(my_id, name, sym, alloc_estate_rl(clone_rl(rl)));
↓ open down ↓ 99 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX