Index: wp-includes/class-wp-image-editor.php
===================================================================
--- wp-includes/class-wp-image-editor.php	(revision 23353)
+++ wp-includes/class-wp-image-editor.php	(working copy)
@@ -326,6 +326,9 @@
 	protected function make_image( $filename, $function, $arguments ) {
 		$dst_file = $filename;
 
+		// The directory containing the original file may no longer exist when using a replication plugin.
+		wp_mkdir_p( dirname( $dst_file ) );
+
 		if ( $stream = wp_is_stream( $filename ) ) {
 			$filename = null;
 			ob_start();
