It is always best to consult with a veterinarian before giving your dog any medications, including over-the-counter anti-diarrheal medications. Some medications may not be suitable for dogs or could have adverse effects on their health. A veterinarian will be able to recommend the most appropriate treatment for your dog's specific condition.