1. 27 1月, 2010 1 次提交
  2. 07 12月, 2009 1 次提交
  3. 25 12月, 2008 1 次提交
    • J
      [S390] drivers/s390/crypto: Move dereference to after IS_ERR test · 21e7b2c4
      Julia Lawall 提交于
      If reply is ERR_PTR(...), then it should not be dereferenced, so I have
      moved the dereference from the declaration to after the IS_ERR test.
      
      The semantic match that finds the problem is as follows:
      (http://www.emn.fr/x-info/coccinelle/)
      
      // <smpl>
      @match exists@
      expression x, E;
      identifier fld;
      position p1,p2;
      @@
      
      (
      x = E;
      |
      x = E
      |
      x@p1->fld
      ... when != x = E
      IS_ERR(x@p2)
      ... when any
      )
      
      @other_match exists@
      expression match.x, E1, E2;
      position match.p1,match.p2;
      @@
      
      x = E1
      ... when != x = E2
          when != x@p1
      x@p2
      
      @ script:python depends on !other_match@
      p1 << match.p1;
      p2 << match.p2;
      @@
      
      print "* file %s dereference %s test %s" % (p1[0].file,p1[0].line,p2[0].line)
      // </smpl>
      Signed-off-by: NJulia Lawall <julia@diku.dk>
      Signed-off-by: NMartin Schwidefsky <schwidefsky@de.ibm.com>
      21e7b2c4
  4. 14 7月, 2008 1 次提交
  5. 17 4月, 2008 1 次提交
  6. 10 7月, 2007 1 次提交
  7. 20 9月, 2006 2 次提交