Index: query.php
===================================================================
--- query.php	(revision 14237)
+++ query.php	(working copy)
@@ -1240,8 +1240,12 @@
 		$this->query_vars = $this->fill_query_vars($this->query_vars);
 		$qv = &$this->query_vars;
 
-		if ( ! empty($qv['robots']) )
+		// is_robots is only true if WP is installed at the root of a domain
+		$home_path = parse_url(home_url());
+		if ( ! empty($qv['robots']) && ( !isset($home_path['path']) || $home_path['path'] == '/' ) )
 			$this->is_robots = true;
+		else 
+			$qv['error'] = '404';
 
 		$qv['p'] =  absint($qv['p']);
 		$qv['page_id'] =  absint($qv['page_id']);
