Fix strict error about references

reset() takes a variable by reference, so previously this was an error.