Why does my kitchen sink smell when the washing machine is running, and what can I do about it?
One or both of these drains are improperly vented. There should be a pipe going up, shortly after each of the traps, to vent the plumbing to the roof. Often this is done inside the wall where you normally wouldn't see it. Without it, the flow of water going down the drain can build up pressure and push sewer gases past the trap and into your home.

The fix is to properly vent the drain, by either removing the blockage in the existing vent, correctly hooking the drain line to the existing vent, or installing a new vent either to the roof or with an air admittance valve.