src/Cedar/SW.c
// Get the directory where the old MSI products are installed

Get the directory where the old MSI products are installed
Get the directory where the old MSI products are installed
wchar_t* SwGetOldMsiInstalledDir(SW_COMPONENT* c)
{
	UINT i;
	if (c == NULL)
	{
		return NULL;
	}
	if (c->OldMsiList == NULL)
	{
		return NULL;
	}
	for (i = 0;i < c->NumOldMsi;i++)
	{
		SW_OLD_MSI* m = &c->OldMsiList[i];
		wchar_t tmp[MAX_SIZE];
		if (MsGetMsiInstalledDir(m->ComponentCode, tmp, sizeof(tmp)))
		{
			return UniCopyStr(tmp);
		}
	}
	return NULL;
}
wchar_t * SwGetOldMsiInstalledDir ( SW_COMPONENT * c ) { UINT i ; if ( c == NULL ) { return NULL ; } if ( c -> OldMsiList == NULL ) { return NULL ; } for ( i = 0 ; i < c -> NumOldMsi ; i ++ ) { SW_OLD_MSI * m = & c -> OldMsiList [ i ] ; wchar_t tmp [ MAX_SIZE ] ; if ( MsGetMsiInstalledDir ( m -> ComponentCode , tmp , sizeof ( tmp ) ) ) { return UniCopyStr ( tmp ) ; } } return NULL ; }
Get the directory where the old MSI products are installed
Get the directory where the old MSI products are installed
// Validate arguments
