Mild and little yellowish discharge on opening of prepuce is normal on male dog. If the yellowish discharge is more than usual, you have to take your dog to see your doctor ASAP. There is a possibility of infection on penis and prepuce area or urethra or bladder etc.