E. Cobham Brewer 18101897. Dictionary of Phrase and Fable. 1898.
Out of the Wood.
You are not out of the wood yet, not yet out of danger. Dont shout till you are out of the wood, do not think yourself safe till you are quite clear of the threatened danger. When freebooters were masters of the forests no traveller was safe till he had got clear of their hunting ground.