No;
If Windows XP is retail and you now have the original CD, Product Key
etc, it is legally your to install on the computer of your choice.
If on the other hand it is OEM, it is normally permanently bound to
the original computer and can never be transferred to another computer
regardless the condition of the original computer.
Read the EULA for details.