Index: /branches/binary/server/memcached.c
===================================================================
--- /branches/binary/server/memcached.c (revision 753)
+++ /branches/binary/server/memcached.c (revision 754)
@@ -70,5 +70,5 @@
 static int try_read_network(conn *c);
 static int try_read_udp(conn *c);
-static void conn_set_state(conn *, int);
+static void conn_set_state(conn *c, enum conn_states state);
 
 /* stats */
@@ -314,5 +314,6 @@
 }
 
-conn *conn_new(const int sfd, const int init_state, const int event_flags,
+conn *conn_new(const int sfd, enum conn_states init_state,
+                const int event_flags,
                 const int read_buffer_size, enum protocol prot,
                 struct event_base *base) {
@@ -513,5 +514,5 @@
 }
 
-static int get_init_state(conn *c) {
+static enum conn_states get_init_state(conn *c) {
     int rv=0;
     assert(c != NULL);
@@ -601,5 +602,5 @@
  * happen here.
  */
-static void conn_set_state(conn *c, int state) {
+static void conn_set_state(conn *c, enum conn_states state) {
     assert(c != NULL);
 
@@ -2726,5 +2727,5 @@
     bool stop = false;
     int sfd, flags = 1;
-    int init_state; /* initial state for a new connection */
+    enum conn_states init_state; /* initial state for a new connection */
     socklen_t addrlen;
     struct sockaddr_storage addr;
Index: /branches/binary/server/memcached.h
===================================================================
--- /branches/binary/server/memcached.h (revision 752)
+++ /branches/binary/server/memcached.h (revision 754)
@@ -217,5 +217,5 @@
 struct conn {
     int    sfd;
-    int    state;
+    enum conn_states  state;
     int    substate;
     struct event event;
@@ -315,5 +315,5 @@
 char *do_add_delta(item *item, const bool incr, const int64_t delta, char *buf);
 int do_store_item(item *item, int comm);
-conn *conn_new(const int sfd, const int init_state, const int event_flags, const int read_buffer_size, enum protocol prot, struct event_base *base);
+conn *conn_new(const int sfd, const enum conn_states init_state, const int event_flags, const int read_buffer_size, enum protocol prot, struct event_base *base);
 
 
@@ -341,5 +341,5 @@
 void thread_init(int nthreads, struct event_base *main_base);
 int  dispatch_event_add(int thread, conn *c);
-void dispatch_conn_new(int sfd, int init_state, int event_flags, int read_buffer_size, enum protocol prot);
+void dispatch_conn_new(int sfd, enum conn_states init_state, int event_flags, int read_buffer_size, enum protocol prot);
 
 /* Lock wrappers for cache functions that are called from main loop. */
