From 9c57f3a4291f2311ae05f22c10eedeb0f69337ab Mon Sep 17 00:00:00 2001
From: Dominik Schilling <dominikschilling+git@gmail.com>
Date: Mon, 14 Sep 2015 22:50:31 +0000
Subject: [PATCH] XMLRPC: Don't allow private posts to be sticky.

Merge of [34135] to the 4.3 branch.

See #20662.
Built from https://develop.svn.wordpress.org/branches/4.3@34151


git-svn-id: http://core.svn.wordpress.org/branches/4.3@34119 1a063a9b-81f0-0310-95a4-ce76da25c4cd

v2: Backport to Wordpress 3.6.1, Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
---
 wp-includes/class-wp-xmlrpc-server.php | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/wp-includes/class-wp-xmlrpc-server.php
+++ b/wp-includes/class-wp-xmlrpc-server.php
@@ -4536,7 +4536,7 @@
 
 		$tags_input = isset( $content_struct['mt_keywords'] ) ? $content_struct['mt_keywords'] : null;
 
-		if ( ('publish' == $post_status) ) {
+		if ( 'publish' == $post_status || 'private' == $post_status ) {
 			if ( ( 'page' == $post_type ) && !current_user_can('publish_pages') )
 				return new IXR_Error(401, __('Sorry, you do not have the right to publish this page.'));
 			else if ( !current_user_can('publish_posts') )
