fix: leak local variable

fixed leak local variable