Barliman appears to have had a rather bad memory, "One thing drives out another" he says. He forgot to send Gandalf's letter to Frodo, leaving Frodo uncertain as to Gandalf's fate and causing him to start his journey much later than the letter indicated. He did not remember it until Frodo and his companions arrived to stay at the inn, and even then it was long before the connection was made. He did, however, remember to produce Strider's credentials.
When Gandalf finally arrives at The Prancing Pony, he's furious with Barliman's forgetfulness, but quickly forgives him when he finds out the Hobbits are alive. He even goes so far as to put a blessing on his beer.
Portrayal in Adaptations
In Peter Jackson's The Fellowship of the Ring, he is played by David Weatherley, although the character is not named and most of his scenes from the book (including the reference to Gandalf's letter) are not in the film.