The reason that Dollhouse was renewed, and Sarah Connor was not, is that Dollhouse was/is also produced by Fox, while Sarah Connor was produced by Warner. Both did not do well in ratings, meaning that the network (in this case, Fox, which is an affiliated, but separate entity from the Fox production studio) did not make enough money by selling ads (sales on iTunes profit only the studio, streaming on Hulu as well, I think; DVR ratings DO profit the network as well, but less than the broadcast ratings since most people fast forward through the ads, so advertisers naturally try to pay less for them).
Besides all that, the (broadcast) ratings for TTSCC were really abysmal; and Joss Whedon is obviously really good at selling himself and promising to produce the next season of 13 episodes of Dollhouse for a lower budget.