I've been on both sides of the podium for this sort of situation, and there are a number of issues that make it not straight-forward to deal with. Most importantly:
- The questioner may misunderstand the material, either because it was presented poorly or just because it's hard to wrap your head around new material in the middle of a talk.
- There are often subtleties that mean the presenter may not be able to analyze a new potential flaw correctly in the moment.
If you are the speaker, then you need to be open to the fact that you are wrong: don't get defensive about your work. At the end of the day, it's not about you: the world is what the world is, and no amount of defending your position will change the facts. If you agree with the questioner about the flaw, then you need to admit it. This has most frequently happened to me when I am giving a class lecture and a student notices a potential mistake on a slide: rather than look at it as a problem, I thank the student and turn sanity checking the equation or algorithm into part of the lesson, where we exercise other knowledge and intuition to check the material. That's generally less possible in a conference talk, of course.
If you disagree or aren't sure that you agree with the questioner, though, don't get into a fight. If you can show they are wrong simply, do so simply and gently, with the assumption that it is a misunderstanding (per first bullet above). If it's complicated or you aren't sure, just say so and offer to talk with them about it more outside of the talk.
Conversely, if you are the questioner, you don't need to make the other person admit defeat. Even if you are right and the other person is confident enough that they would be willing to admit it, they may not be in a position to do so because they've only had 30 seconds to consider it and aren't certain enough whether they agree with your critique. And if the speaker is not self-confident, they may be too afraid of losing face to admit an error directly. That doesn't matter: if you raise an issue publicly, such that the rest of the audience is not blindly accepting a dubious element of the work, that is enough.