Sophie

Sophie

distrib > Fedora > 16 > i386 > by-pkgid > 92d2bfb5a363004a8a399eefe5c79f14 > files > 19

coccinelle-examples-1.0.0-0.rc4.2.fc16.i686.rpm

@@
identifier proc_info_func;
identifier buffer, start, offset, length, inout, hostno;
identifier hostptr;
typedef off_t;
@@
  proc_info_func (
+      struct Scsi_Host *hostptr,
       char *buffer, char **start, off_t offset, int length, 
-      int hostno, 
       int inout) {
    ...
-   struct Scsi_Host *hostptr;
    ...
-   hostptr = scsi_host_hn_get(hostno);
    ...
-   if (!hostptr) { ... return ...; }
    ...
-   scsi_host_put(hostptr);
    ...
  }