Onions are toxic to cats--the toxicity is dose dependant. If this just happened talk to your veterinarian about inducing vomiting to rid the stomach of the onions. They will also be able to tell you if the amount ingested is likely to be a problem. If your cat is sick or ate a large amount of onions more than 2-4 hours ago then your cat needs to be examined by a veterinarian. They will run blood work--onion toxicity results in hemolytic anemia and can be very severe.
Don't smell his breath lol! My cat eats strange things all the time and I don't think its anything to worry about.