Fabian Groffen wrote:
Hi all,
Triggered by a request from a user I changed the mapilib example somewhat. In particular, I tried to make the example more "school style", e.g. don't use a define for something which could have been a function. More important, I added code to walk multi-resultset handles in case there is an error, such that it eventually gets printed. I also closed the handle in the die function as proper cleanup example. I removed some mapi_error checks that I thought were redundant, but I'm not sure. Hence, please review the attached diff and comment before I commit this.
The example compiles without warnings for me now, and also works for as far as I can see.
The problem with your patch (as I see it) is that if you try to execute a multi query batch of which one part fails, your error handling code doesn't show the results that you get from the part(s) that succeed. How bad this is is a matter of opinion. In the cases where your code is used, there are no batches of multiple queries, so the situation does not occur. -- Sjoerd Mullender