Initialize "buf" to 0 to make valgrind happy :-)