First, take a deep breath.
There's a huge spectrum in significance and implications of this diagnosis. It depends on the exact diagnosis, its severity, its prognosis, and what management options exist. Confirmation by second opinion may be indicated, especially since you're upset. You are not the first or only one with this diagnosis, so support from others will be available. Talk to your doctor.