### Eclipse Workspace Patch 1.0
#P wordpress-trunk
Index: wp-admin/includes/misc.php
===================================================================
--- wp-admin/includes/misc.php	(revision 17562)
+++ wp-admin/includes/misc.php	(working copy)
@@ -65,8 +65,9 @@
  * @return bool True on write success, false on failure.
  */
 function insert_with_markers( $filename, $marker, $insertion ) {
-	if (!file_exists( $filename ) || is_writeable( $filename ) ) {
-		if (!file_exists( $filename ) ) {
+	$file_exists = file_exists( $filename );
+	if (!$file_exists || is_writeable( $filename ) ) {
+		if (!$file_exists ) {
 			$markerdata = '';
 		} else {
 			$markerdata = explode( "\n", implode( '', file( $filename ) ) );
@@ -105,6 +106,8 @@
 			fwrite( $f, "# END {$marker}\n" );
 		}
 		fclose( $f );
+		if (!$file_exists)
+			chmod( $filename, FS_CHMOD_FILE );
 		return true;
 	} else {
 		return false;
