Alistair Leslie-Hughes wrote:
Hi, I just added a check for a null pointer since we deference it.
Changelog: mapi32: stop crash under win98
Best Regards Alistair Leslie-Hughes
+ if(lpResProp->Value.MVszA.lppszA) + { + ok(lpResProp->Value.MVszA.lppszA[0] == buffer + sizeof(SPropValue) + sizeof(char*), + "wrong lppszA[0] %p\n",lpResProp->Value.MVszA.lppszA[0]); + ok(!strcmp(lpResProp->Value.MVszA.lppszA[0], szTestA), + "wrong string '%s'\n", lpResProp->Value.MVszA.lppszA[0]); + } + else + { + skip("lpResProp->Value.MVszA.lppszA is NULL"); + }
I'm not sure if skip() is appropriate here as we are not skipping a function call and we're not skipping subsequent function calls because of this.
If Win98 is plainly wrong, and the test maybe has to be changed, here it should probably be:
ok(0, "lpResProp->Value.MVszA.lppszA is NULL");
If it's perfectly valid for win98 to return that NULL value is should probably be a trace() as we still have to overcome the dereferencing.