The fact that this question is being asked gives some insight into Tom's behavior later in the story. In short, Tom probably couldn't do anything to change his fate, but people tend to look for limits and loopholes when terms are unfavorable to them. This might even be considered an insight into human moral behaviors (see reference below, Kohlberg's Stages of Morality). Tom, and many people who would "fight fate" under these circumstances, may in fact be exhibiting a very poor abstract moral code, but a very strong preservation instinct.
The most obvious way that Tom could have gotten out of the deal was by not making it in the first place; it was clear that he was under no obligation to commit to it, and that Scratch was neither pressing him nor really all that interested in pursuing the matter. Scratch already knew that Tom's greed would do the work for him. However, from this perspective, and the perspective of the story as a moral fable, Tom's greed predicted his behavior, and he was basically doomed to sign the contract because that's what a simplistic, amoral character would do.
Once involved in the contract, there wasn't really any stated way for Tom to go back on the deal. Hypothetically he might have tried returning the treasure, but this would not undo the sins that Tom had performed using it. It's also ironic that Tom begins to go to church and read a Bible, but continues lending money just as he was instructed to by the Devil.
Thus, I think that while we might abstractly argue that there could have been some way of getting out of the deal, there was no way for Tom, specifically, to do so, because he lacked the moral character to act beyond the behaviors dictated by his personality.