Was the person that told you assuming or do they know for sure? Otherwise I don’t think you should end your friendship because of this, but you should try not to lead him on in any way in the time he decides whether or not to confess. Do whatever makes you comfortable.. you can also just distance yourself and make it clear you’re uninterested