Remove SSL_in_before and SSL_ST_BEFORE.

It's never called and the state is meaningless now.

Change-Id: I5429ec3eb7dc2b789c0584ea88323f0ff18920ae
Reviewed-on: https://boringssl-review.googlesource.com/4826
Reviewed-by: Adam Langley <agl@google.com>
diff --git a/include/openssl/ssl.h b/include/openssl/ssl.h
index f20201c..aee6e18 100644
--- a/include/openssl/ssl.h
+++ b/include/openssl/ssl.h
@@ -1486,7 +1486,6 @@
 #define SSL_ST_ACCEPT 0x2000
 #define SSL_ST_MASK 0x0FFF
 #define SSL_ST_INIT (SSL_ST_CONNECT | SSL_ST_ACCEPT)
-#define SSL_ST_BEFORE 0x4000
 #define SSL_ST_OK 0x03
 #define SSL_ST_RENEGOTIATE (0x04 | SSL_ST_INIT)
 
@@ -1508,7 +1507,6 @@
 #define SSL_get_state(a) SSL_state(a)
 #define SSL_is_init_finished(a) (SSL_state(a) == SSL_ST_OK)
 #define SSL_in_init(a) (SSL_state(a) & SSL_ST_INIT)
-#define SSL_in_before(a) (SSL_state(a) & SSL_ST_BEFORE)
 #define SSL_in_connect_init(a) (SSL_state(a) & SSL_ST_CONNECT)
 #define SSL_in_accept_init(a) (SSL_state(a) & SSL_ST_ACCEPT)
 
diff --git a/ssl/d1_clnt.c b/ssl/d1_clnt.c
index bd72e2f..92fb8f6 100644
--- a/ssl/d1_clnt.c
+++ b/ssl/d1_clnt.c
@@ -156,7 +156,6 @@
 
     switch (s->state) {
       case SSL_ST_CONNECT:
-      case SSL_ST_BEFORE | SSL_ST_CONNECT:
         if (cb != NULL) {
           cb(s, SSL_CB_HANDSHAKE_START, 1);
         }
diff --git a/ssl/d1_srvr.c b/ssl/d1_srvr.c
index 3fbfb0c..037641b 100644
--- a/ssl/d1_srvr.c
+++ b/ssl/d1_srvr.c
@@ -160,7 +160,6 @@
 
     switch (s->state) {
       case SSL_ST_ACCEPT:
-      case SSL_ST_BEFORE | SSL_ST_ACCEPT:
         if (cb != NULL) {
           cb(s, SSL_CB_HANDSHAKE_START, 1);
         }
diff --git a/ssl/s3_clnt.c b/ssl/s3_clnt.c
index fe5e89d..abfd36c 100644
--- a/ssl/s3_clnt.c
+++ b/ssl/s3_clnt.c
@@ -194,7 +194,6 @@
 
     switch (s->state) {
       case SSL_ST_CONNECT:
-      case SSL_ST_BEFORE | SSL_ST_CONNECT:
         if (cb != NULL) {
           cb(s, SSL_CB_HANDSHAKE_START, 1);
         }
diff --git a/ssl/s3_srvr.c b/ssl/s3_srvr.c
index 5445358..d0adce6 100644
--- a/ssl/s3_srvr.c
+++ b/ssl/s3_srvr.c
@@ -208,7 +208,6 @@
 
     switch (s->state) {
       case SSL_ST_ACCEPT:
-      case SSL_ST_BEFORE | SSL_ST_ACCEPT:
         if (cb != NULL) {
           cb(s, SSL_CB_HANDSHAKE_START, 1);
         }
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c
index e84079a..cca4dd1 100644
--- a/ssl/ssl_lib.c
+++ b/ssl/ssl_lib.c
@@ -2111,7 +2111,7 @@
 void SSL_set_accept_state(SSL *ssl) {
   ssl->server = 1;
   ssl->shutdown = 0;
-  ssl->state = SSL_ST_ACCEPT | SSL_ST_BEFORE;
+  ssl->state = SSL_ST_ACCEPT;
   ssl->handshake_func = ssl->method->ssl_accept;
   /* clear the current cipher */
   ssl_clear_cipher_ctx(ssl);
@@ -2120,7 +2120,7 @@
 void SSL_set_connect_state(SSL *ssl) {
   ssl->server = 0;
   ssl->shutdown = 0;
-  ssl->state = SSL_ST_CONNECT | SSL_ST_BEFORE;
+  ssl->state = SSL_ST_CONNECT;
   ssl->handshake_func = ssl->method->ssl_connect;
   /* clear the current cipher */
   ssl_clear_cipher_ctx(ssl);
diff --git a/ssl/ssl_stat.c b/ssl/ssl_stat.c
index 8bed9ad..fa5541b 100644
--- a/ssl/ssl_stat.c
+++ b/ssl/ssl_stat.c
@@ -105,14 +105,6 @@
       str = "SSL renegotiate ciphers";
       break;
 
-    case SSL_ST_BEFORE | SSL_ST_CONNECT:
-      str = "before/connect initialization";
-      break;
-
-    case SSL_ST_BEFORE | SSL_ST_ACCEPT:
-      str = "before/accept initialization";
-      break;
-
     /* SSLv3 additions */
     case SSL3_ST_CW_CLNT_HELLO_A:
       str = "SSLv3 write client hello A";