If you are using Windows (I have Windows XP), this worked for me:
1. Quit iTunes.
2. Start Menu -> All Programs -> Accessories -> Right Click "Command Prompt" -> "Run as Administrator" (If you don't have this option, just select "Current User")
3. In the command prompt type "netsh winsock reset" and hit ENTER.
4. Reboot your machine.
5. Restart iTunes
6. Plug in your iPhone and run sync again.
