libao_pulse buffer calculation overflow
In tracking down the source of some strange behavior when setting buffer_time for the pulse plugin, I found a bug in the buffer length calculations that results in a multiplication overflow for some values. This overflow would set the buffer size to some absurdly-large value (~30 seconds in my case).
I've attached a patch that casts the multiplicands to a 64-bit int before the multiplication. This fixed the issue for me.