If the brakes lock when the engine runs without even moving,
Take a look at the vacuum booster vacuum hose.
There is a check-valve there. try swapping it end for end and see what happens.
If the same thing occurs, try removing the check valve and inserting
a straight-through tube in it's place.
Keep us posted.-Bob