Prove $\gcd(a+b,a^2+b^2)$ is $1$ or $2$ if $\gcd(a,b) = 1$ 
Assuming that $\gcd(a,b) = 1$, prove that $\gcd(a+b,a^2+b^2) = 1$ or $2$.

I tried this problem and ended up with
$$d\mid 2a^2,\quad d\mid 2b^2$$
where $d = \gcd(a+b,a^2+b^2)$, but then I am stuck; by these two conclusions how can I conclude $d=1$ or $2$? 
And also is there any other way of proving this result?

If $d$ divides $a+b$ then it divides $a(a+b)=a^2+ab$ so if it also divides $a^2+b^2$ then it divides $a^2+ab-(a^2+b^2)=ab-b^2=b(a-b)$. A similar calculation shows it divides $a(a-b)$. Then from $\gcd(a,b)=1$ we get $d$ divides $a-b$. But then it divides $(a+b)+(a-b)=2a$ and $(a+b)-(a-b)=2b$, so it's 1 or 2. 
