The decision tree for the problem in the OP:
----------------------------------------
1/3 Tom will be executed
1/2 Dick will be named
1/2 Harry will be named
1/3 Dick will be executed
1 Harry will be named
1/3 Harry will be executed
1 Dick will be named
----------------------------------------
The outcomes, noted {executed,named}, and their probabilities are as follows:
{Tom,Dick}|1/3 * 1/2 = |1/6
{Tom,Harry}|1/3 * 1/2 = |1/6
{Dick,Harry}|1/3 * 1 = | 1/3
{Harry,Dick}|1/3 * 1 = | 1/3
Eliminating the possibilities where Dick is not named:
{Tom,Dick}|1/6
{Tom,Harry}
|1/6
{Dick,Harry}
|1/3
{Harry,Dick}|1/3
Of the two that are left, Harry is executed (1/3)/(1/3+1/6) = 2/3, and Tom is executed (1/6)/(1/3+1/6) = 1/3.
Contrast this to the case where the person that is going to be named as going free does not exclude Tom as a possibility:
----------------------------------------
1/3 Tom is executed
1/2 Dick is named
1/2 Harry is named
1/3 Dick is executed
1/2 Tom is named
1/2 Harry is named
1/3 Harry is executed
1/2 Tom is named
1/2 Dick is named
----------------------------------------
Making the outcomes:
{Tom,Dick}|1/3 * 1/2 = |1/6
{Tom,Harry}|1/3 * 1/2 = |1/6
{Dick,Tom}|1/3 * 1/2 = |1/6
{Dick,Harry}|1/3 * 1/2 = |1/6
{Harry,Tom}|1/3 * 1/2 = |1/6
{Harry,Dick}|1/3 * 1/2 = |1/6
Removing the outcomes where Dick is not named:
{Tom,Dick}|1/6
{Tom,Harry}
|1/6
{Dick,Tom}
|1/6
{Dick,Harry}
|1/6
{Harry,Tom}
|1/6
{Harry,Dick}|1/6
Tom is executed (1/6)/(2/6) = 1/2, Harry is executed (1/6)/(2/6) = 1/2.