Use a collection to cache results from your first Dir() loop: then run your second loop on each of those items:
Sub Traverse()
Dim col As New Collection, fpath, f, d, root
root = "C:\_stuff\test\"
d = Dir(root, vbDirectory)
Do While d <> ""
If (GetAttr(root & d) And vbDirectory) <> 0 Then
If d <> "." And d <> ".." Then col.Add root & d
End If
d = Dir()
Loop
For Each fpath In col
f = Dir(fpath & "\*.txt")
While f <> ""
'do something with f
f = Dir()
Wend
Next
End Sub