Changed NULL to 0 whenever unbinding a buffer to make compiler happy.