From 2572fb6fb41a82c78b51c1a981759065fc363b02 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Tue, 24 Sep 2013 21:34:59 +0900 Subject: [PATCH] shrpx.cc: Code cleanup --- src/shrpx.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/shrpx.cc b/src/shrpx.cc index b06938d8..d72cd13b 100644 --- a/src/shrpx.cc +++ b/src/shrpx.cc @@ -275,9 +275,8 @@ int event_loop() save_pid(); } - evconnlistener *evlistener6, *evlistener4; - evlistener6 = create_evlistener(listener_handler, AF_INET6); - evlistener4 = create_evlistener(listener_handler, AF_INET); + auto evlistener6 = create_evlistener(listener_handler, AF_INET6); + auto evlistener4 = create_evlistener(listener_handler, AF_INET); if(!evlistener6 && !evlistener4) { LOG(FATAL) << "Failed to listen on address " << get_config()->host << ", port " << get_config()->port;