I had the same error when updating to 1.5.1 from 1.1 on win 7 SP3 32bit
I can confirm removing the folder 'my documents\Arduino\Hardware' fixes the problem (I had additional boards installed in this folder, the Sparkfun Micro)
best regards,
Lieven Standaert