Whether you're looking to lose fat, put muscle on or both, this a problem.
The Overweight (not obese)
By restricting your calories too severely you are slowing down your metabolism and losing lean mass (muscle) - which makes it much harder for you to lose weight. Therefore, I tend to surprise these clients by telling them to eat more food to lose weight! Under my careful guidance, I will slowly increase the calories to their body's sub-maintenance level and give them a detailed food plan to ensure they're eating the right foods at the right times; they end up losing more weight but in a sustainable way!!!!
The Lean Person
In order to put on weight you need to have a surplus of calories. Taking in lots of protein but not enough calories, won't lead to optimal results. Therefore, I would increase the calories to above maintenance levels, ensure they're eating the correct foods as well as taking the right supplementation to pack on the muscle!
p.s. though this isn't a licence to eat everything in sight!!!!!! :-) http://www.samwattfitness.com/testimonials.html