diff --git a/src/tcp_sample.c b/src/tcp_sample.c index 925b93291..12eb25c4e 100644 --- a/src/tcp_sample.c +++ b/src/tcp_sample.c @@ -176,7 +176,7 @@ int smp_fetch_dst_is_local(const struct arg *args, struct sample *smp, const cha if (kw[0] == 'f') { /* fc_dst_is_local */ struct connection *conn = objt_conn(smp->sess->origin); - if (conn && conn_get_src(conn)) + if (conn && conn_get_dst(conn)) dst = conn_dst(conn); } else /* dst_is_local */ @@ -232,10 +232,10 @@ smp_fetch_dport(const struct arg *args, struct sample *smp, const char *kw, void if (conn && conn_get_dst(conn)) dst = conn_dst(conn); } - else if (kw[0] == 'f') { /* fc_dst_post */ + else if (kw[0] == 'f') { /* fc_dst_port */ struct connection *conn = objt_conn(smp->sess->origin); - if (conn && conn_get_src(conn)) + if (conn && conn_get_dst(conn)) dst = conn_dst(conn); } else /* dst_port */