Necrotising fasciitis is the clinical name for what is mistakenly known as 'flesh eating bacteria'. The bacteria that cause this infection do not eat the flesh but infect it, spread all over it and damage it with toxins. It is rare to develop this in a healthy individual as it tends to affect only people with severely compromised immune systems. Several common bacteria such as streptococci, staphylococci can 'turn' nasty in those with very poor immune systems and tissue damage and case an infection that spreads through the tissue planes causing lasting damage.
Once infection occurs the best treatment is wound debridement, very strong intravenous antibiotics and surgery to salvage the area.
Garlic is associated with boosting immune systems but this is more a possible preventive measure rather than a valid treatment option. Consuming regular garlic helps to keep our immune system healthy apart from other factors of physical health.