Sometimes the character has to be a jerk
Sometimes I hear people talking about book characters as if they are real people, arguing about why they did such-and-such or where they really should've ended up, and so on. As a writer, that's one of my favorite things, when readers talk about my characters that way. It means I've achieved suspension of disbelief!
On occasion, readers disapprove of something the character has done. "She was too whiny there." "I don't see why he had to be so mean to Character X." "Why did she have to stab her friend in the back like that?" (These are made-up quotes, by the way, just to catch the spirit of what I'm talking about.)
Mostly, we want writers to like our main characters, to identify with them. (There are exceptions.) It's okay if the villain is a jerk--villains are supposed to be jerks. But what about when our beloved main character strays into jerkitude?
It can be painful to know that a reader might not like what the character's doing in a particular scene, but it's necessary for the story. Our main characters sometimes act like jerks because human beings, in general, sometimes act like jerks. Perfect characters are boring, and perfect people don't exist. I'm fond of my characters partly because they sometimes act like jerks--I suppose because I can usually see the pain or desire underneath. That's what's interesting: when they're driven by something, when they're hurting or yearning but won't admit it. If they always did the right thing and were open and honest about everything, well--then there probably wouldn't be much of a story.