Garlic is extremely low in acid. If it is stored improperly in oil (without oxygen) and in warm temperatures (at room temperature), it can produce a toxin that causes botulism. Botulism can be fatal if not treated immediately. It is very important to refrigerate garlic confit, as per the Center for Disease Control.  Use a clean jar with a tight seal to store garlic confit; cool the garlic and oil as quickly as possible, and refrigerate it immediately. If you store the preserved garlic properly, it should keep for several months, however, to be completely safe, I recommend only storing it for up to three weeks. If you’re worried, you can also safely freeze garlic confit for several months.