|MadSci Network: Anatomy|
Well the short answer is that it does not cause you to pass out. By locking the knees, you diminish the use of the muscles in your legs which normally increases the blood return from the legs. As blood pools in the veins of your legs, your heart has less blood returning to be sent to the brain. By unlocking your knees, you are forced to use the muscles in the legs more for the position of standing. There is no artery that gets blocked in the knees and causes the phenomenon. Admin Note - It takes quite a long time of standing with the knees locked before one begins to feel light-headed and eventually pass out. This is affected by temperature, with fainting more likely on hot days. But in any event, the key is standing with knees locked for long periods, not simply locking your knees.
Try the links in the MadSci Library for more information on Anatomy.