logcontract(2*log(x+1)) => log((x+1)^2)
logcontract(2*log(x+1)+1) => log(x^2+2*x+1)+1
That is, it performs a ratsimp only in the second case.
logcontract is documented to perform the ratsimp, in
fact. But in general, it doesn't seem like a good idea.
Consider, e.g. logcontract(1000*log(x+1)+log(x)). This
stack-overflows since it expands out the result, but it
could just as well return log((x+1)^1000*x).
There is a workaround, which is to bind ratfac to true,
which leaves things in factored form. Perhaps
logcontract should always have ratfac:true?