Mixed state in magnetic superconductors