Lines 2201-2212
Link Here
|
2201 |
|
2201 |
|
2202 |
char *sfv245_check_status(SFSample *spp, struct sockaddr *sa) |
2202 |
char *sfv245_check_status(SFSample *spp, struct sockaddr *sa) |
2203 |
{ |
2203 |
{ |
|
|
2204 |
struct sockaddr salocal; |
2204 |
u_int32_t aux1 = spp->agentSubId; |
2205 |
u_int32_t aux1 = spp->agentSubId; |
2205 |
int hash = hash_status_table(aux1, sa, XFLOW_STATUS_TABLE_SZ); |
|
|
2206 |
struct xflow_status_entry *entry = NULL; |
2206 |
struct xflow_status_entry *entry = NULL; |
|
|
2207 |
int hash; |
2208 |
|
2209 |
memcpy(&salocal, sa, sizeof(struct sockaddr)); |
2210 |
( (struct sockaddr_in *)&salocal )->sin_addr = spp->agent_addr.address.ip_v4; |
2211 |
hash = hash_status_table(aux1, &salocal, XFLOW_STATUS_TABLE_SZ); |
2207 |
|
2212 |
|
2208 |
if (hash >= 0) { |
2213 |
if (hash >= 0) { |
2209 |
entry = search_status_table(sa, aux1, hash, XFLOW_STATUS_TABLE_MAX_ENTRIES); |
2214 |
entry = search_status_table(&salocal, aux1, hash, XFLOW_STATUS_TABLE_MAX_ENTRIES); |
2210 |
update_status_table(entry, spp->sequenceNo); |
2215 |
update_status_table(entry, spp->sequenceNo); |
2211 |
entry->inc = 1; |
2216 |
entry->inc = 1; |
2212 |
} |
2217 |
} |