Index: src/wp-includes/query.php
===================================================================
--- src/wp-includes/query.php	(revision 36216)
+++ src/wp-includes/query.php	(working copy)
@@ -4956,10 +4956,6 @@
 function wp_old_slug_redirect() {
 	global $wp_query, $wp_rewrite;
 
-	if ( get_queried_object() ) {
-		return;
-	}
-
 	if ( '' !== $wp_query->query_vars['name'] ) :
 		global $wpdb;
 
@@ -5015,6 +5011,9 @@
 					$link = user_trailingslashit( trailingslashit( $link ) . $endpoint[1] );
 				}
 			}
+		} else {
+			// If it wasn't a 404, then it's going to be handled elsewhere.
+			return;
 		}
 
 		/**
