Some changes in preparation of stricter rules about mixing str and bytes.
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index 22a57ea..284910d 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -403,18 +403,16 @@
 	char *str;
 	Py_ssize_t size;
 
-	if (!PyObject_CheckReadBuffer(cmd) &&
-	    !PyUnicode_Check(cmd)) {
-		PyErr_SetString(PyExc_TypeError,
-			   "eval()/exec() arg 1 must be a string, bytes or code object");
-		return NULL;
-	}
-
 	if (PyUnicode_Check(cmd)) {
 		cmd = _PyUnicode_AsDefaultEncodedString(cmd, NULL);
 		if (cmd == NULL)
 			return NULL;
 	}
+	else if (!PyObject_CheckReadBuffer(cmd)) {
+		PyErr_SetString(PyExc_TypeError,
+		  "eval()/exec() arg 1 must be a string, bytes or code object");
+		return NULL;
+	}
 	if (PyObject_AsReadBuffer(cmd, (const void **)&str, &size) < 0) {
 		return NULL;
 	}