X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Frconn.c;h=b18a2e59e918c3d4373b3a4e19a0bcf55b6e6af6;hb=e9e28be359f64c03944c0a282c17e714fcb0afc4;hp=deb95195deac5ffd93225716ca3f3a6d1974fa27;hpb=a14bc59fb8f27db193d74662dc9c5cb8237177ef;p=openvswitch diff --git a/lib/rconn.c b/lib/rconn.c index deb95195..b18a2e59 100644 --- a/lib/rconn.c +++ b/lib/rconn.c @@ -698,6 +698,15 @@ rconn_get_last_connection(const struct rconn *rc) return rc->last_connected; } +/* Returns the time at which the last OpenFlow message was received by 'rc'. + * If no packets have been received on 'rc', returns the time at which 'rc' + * was created. */ +time_t +rconn_get_last_received(const struct rconn *rc) +{ + return rc->last_received; +} + /* Returns the time at which 'rc' was created. */ time_t rconn_get_creation_time(const struct rconn *rc)