13 Dec
2018
13 Dec
'18
12:23 p.m.
Would it make sense to swap case order and merge/fallthrough? On 13/12/2018 10:39, Huw Davies wrote:
- ReleaseStgMedium(pStgMedium); + switch (med->tymed) + { + case TYMED_NULL: + case TYMED_FILE: + case TYMED_ISTREAM: + case TYMED_ISTORAGE: + ReleaseStgMedium(med); + break; + case TYMED_HGLOBAL: + case TYMED_GDI: + case TYMED_MFPICT: + case TYMED_ENHMF: + if (LOWORD(*flags) == MSHCTX_INPROC) + med->tymed = TYMED_NULL; + ReleaseStgMedium(med); + break; + default: + RaiseException(DV_E_TYMED, 0, 0, NULL); + }
--