Index: src/wp-includes/ms-load.php
===================================================================
--- src/wp-includes/ms-load.php	(revision 41324)
+++ src/wp-includes/ms-load.php	(working copy)
@@ -312,18 +312,18 @@
 		 * If we're not dealing with one of these installations, then the important part is determining
 		 * the network first, because we need the network's path to identify any sites.
 		 */
-		if ( ! $current_site = wp_cache_get( 'current_network', 'site-options' ) ) {
-			// Are there even two networks installed?
-			$one_network = $wpdb->get_row( "SELECT * FROM $wpdb->site LIMIT 2" ); // [sic]
-			if ( 1 === $wpdb->num_rows ) {
-				$current_site = new WP_Network( $one_network );
-				wp_cache_add( 'current_network', $current_site, 'site-options' );
-			} elseif ( 0 === $wpdb->num_rows ) {
-				// A network not found hook should fire here.
-				return false;
-			}
+		// Are there even two networks installed?
+		$network_query = new WP_Network_Query();
+		$args          = array( 'number' => 2 );
+		$networks      = $network_query->query( $args );
+		if ( 1 === $network_query->found_networks ) {
+			$current_site = array_shift( $networks );
+		} elseif ( 0 === $network_query->found_networks ) {
+			// A network not found hook should fire here.
+			return false;
 		}
 
+
 		if ( empty( $current_site ) ) {
 			$current_site = WP_Network::get_by_path( $domain, $path, 1 );
 		}
