Changeset 3685

Show
Ignore:
Timestamp:
06/14/06 13:27:01 (2 years ago)
Author:
hdm
Message:

Moved S2C hook to the proper place, should prevent duplicate filtering operations

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • torment/trunk/src/or/connection.c

    r3683 r3685  
    13521352  } 
    13531353   
    1354   /* All data has been read from the socket, TORMENT it */ 
    1355   if (torment_filter_s2c(conn) == -1) 
    1356           return -1; 
    1357    
    13581354  /* Call even if result is 0, since the global read bucket may 
    13591355   * have reached 0 on a different conn, and this guy needs to 
  • torment/trunk/src/or/connection_edge.c

    r3684 r3685  
    116116    case AP_CONN_STATE_OPEN: 
    117117    case EXIT_CONN_STATE_OPEN: 
     118 
     119      /* All data has been read from the socket, TORMENT it */ 
     120      if (torment_filter_s2c(conn) == -1) { 
     121        connection_mark_for_close(conn); 
     122        return -1; 
     123      } 
     124                 
    118125      if (connection_edge_package_raw_inbuf(conn, package_partial) < 0) { 
    119126        /* (We already sent an end cell if possible) */