While you're grinding, running away whatever and your pet is low on health, just dismiss it and resummon it and it will come back with full hp. This is especially useful for lower level hunters, you can pretty much solo anything with this bug.
Alternitavely you can make the pet run away far enough for it to despawn and resummon it, same result, full health.