You should let your dentist know this and they will sometimes write you a prescription for an antibiotic. They will instruct you to start taking it a few days before you come in for your dental appointment.
You can also take a vitamin C supplement. That helps boost your body's immune system. Also, you can gargle hydrogen peroxide. First dilute it, it should have the instructions on the bottle. If you don like that idea, you can gargle mouthwash, like Listerine, about 3-5 times a day for about 5 days. That should give your mouth some time to heal.