A Duke student struggled with a man who tried to rob him, resulting in gunfire that wounded him and possibly the would-be robber, Durham police said.