I was reading at this.. and it doesn't seem to be good advice.. I still prefer the previous post:
Write it down. This is really important. When your boss says or does something inappropriate, write a memo stating that the behavior is unacceptable, distracts from work, and you want it to stop. If it happens again, copy her/his boss, or an HR manager, on your second memo to the boss.
-> i doubt it works in most companies (unless the HR is really neutral)
The next time you are getting ready to work on a big project, run off a few documents and attach a formal memo, with the date an your name, to one of the documents stating "This looks good to me, but I wanted to run it past you. What do you think?" and date the note. Make a quick copy and tuck it in a CYA file. If your boss does not answer the memo, write another one saying, "Since you haven't responded, I am proceeding on this project with your approval." If others work on the project with you, copy them on the memo.
-> they are even better than me collecting our mistakes
Update your resume and begin a job search just in case your boss continues to abuse you.
Recognize that it may be time to leave if you are becoming ill, physically or mentally. You may spend more on doctor's bill than you make, if you allow the abuse to continue. When you feel you must leave, give two weeks notice in writing. Try to have another job lined up first. Be aware that your boss may ask you to leave immediately--in this case, two weeks pay is often offered.