There is nothing inherently wrong with performing stock buybacks, from a cashflow perspective it is equivalent of paying a dividend, in fact it can be prudent from a tax perspective. You did imply that it is a continuous process when you suggested:
> when the money runs out, the buybacks stop
Performing a stock buyback based off the proceeds of debt in a down market makes perfect sense actually because you can significantly reduce your cost of capital if you believe your future cashflow will be strong enough to continue making coupon payments. You can issue debt at say 3.5% and buy out shares that require 7% cost of capital and as long as interest rate and credit risk don't drastically deteriorate significantly increase the value of your company from a simple capital markets operation.