The submitblock patch given earlier in the thread and merged in the code breaks the submitblock API.
If the block is accepted, submitblock is supposed to return Null, not True:
https://github.com/bitcoin/bips/blob/master/bip-0022.mediawiki#Block_SubmissionThis method MUST return either null (when a share is accepted), a String describing briefly the reason the share was rejected, or an Object of these with a key for each merged-mining chain the share was submitted to.
Line 1874 in bitcoinrpc.cpp needs to be changed from:
return true;
to
return Value::null;
Yes you are right. This was the code from another member for the mining pool. I fixed it and checked in github. Thanks for the info!