35static const char *
msifile =
"winetest-patch.msi";
36static const char *
mspfile =
"winetest-patch.msp";
45 "Property\tProperty\n"
46 "Manufacturer\tWineHQ\n"
47 "ProductCode\t{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}\n"
48 "UpgradeCode\t{A2E3D643-4E2C-477F-A309-F76F552D5F43}\n"
49 "ProductLanguage\t1033\n"
50 "ProductName\tmsitest\n"
51 "ProductVersion\t1.1.1\n"
52 "PATCHNEWSUMMARYSUBJECT\tInstaller Database\n"
53 "MSIFASTINSTALL\t1\n";
56 "DiskId\tLastSequence\tDiskPrompt\tCabinet\tVolumeLabel\tSource\n"
57 "i2\ti4\tL64\tS255\tS32\tS72\n"
59 "1\t1\t\t\tDISK1\t\n";
62 "File\tComponent_\tFileName\tFileSize\tVersion\tLanguage\tAttributes\tSequence\n"
63 "s72\ts72\tl255\ti4\tS72\tS20\tI2\ti2\n"
65 "patch.txt\tpatch\tpatch.txt\t1000\t\t\t0\t1\n"
66 "disable.txt\tdisable\tdisable.txt\t1000\t\t\t0\t1\n";
69 "Directory\tDirectory_Parent\tDefaultDir\n"
71 "Directory\tDirectory\n"
72 "MSITESTDIR\tProgramFilesFolder\tmsitest\n"
73 "ProgramFilesFolder\tTARGETDIR\t.\n"
74 "TARGETDIR\t\tSourceDir";
77 "Component\tComponentId\tDirectory_\tAttributes\tCondition\tKeyPath\n"
78 "s72\tS38\ts72\ti2\tS255\tS72\n"
79 "Component\tComponent\n"
80 "patch\t{4B79D87E-6D28-4FD3-92D6-CD9B26AF64F1}\tMSITESTDIR\t0\t\tpatch.txt\n"
81 "disable\t{BDDBA0EE-0031-4591-ADC0-33308175AC19}\tMSITESTDIR\t0\t\tdisable.txt\n";
84 "Feature\tFeature_Parent\tTitle\tDescription\tDisplay\tLevel\tDirectory_\tAttributes\n"
85 "s38\tS38\tL64\tL255\tI2\ti2\tS72\ti2\n"
87 "patch\t\t\tpatch feature\t1\t1\tMSITESTDIR\t0\n"
88 "disable\t\t\tdisabled feature\t1\t1\tMSITESTDIR\t0\n";
91 "Feature_\tComponent_\n"
93 "FeatureComponents\tFeature_\tComponent_\n"
98 "Action\tCondition\tSequence\n"
100 "InstallExecuteSequence\tAction\n"
101 "LaunchConditions\t\t100\n"
102 "CostInitialize\t\t800\n"
104 "CostFinalize\t\t1000\n"
105 "InstallValidate\t\t1400\n"
106 "InstallInitialize\t\t1500\n"
107 "ProcessComponents\t\t1600\n"
108 "RemoveFiles\t\t1700\n"
109 "InstallFiles\t\t2000\n"
110 "RegisterUser\t\t3000\n"
111 "RegisterProduct\t\t3100\n"
112 "PublishFeatures\t\t5100\n"
113 "PublishProduct\t\t5200\n"
114 "UnpublishFeatures\t\t5300\n"
115 "InstallFinalize\t\t6000\n";
118 "Feature_\tLevel\tCondition\n"
120 "Condition\tFeature_\tLevel\n"
121 "disable\t0\tDISABLE_FEATURE\n";
253 for (
i = 0;
i < num_tables;
i++)
276static const WCHAR p_name0[] = { 0x4840, 0x3b3f, 0x43f2, 0x4438, 0x45b1, 0 };
277static const WCHAR p_name1[] = { 0x4840, 0x3f7f, 0x4164, 0x422f, 0x4836, 0 };
278static const WCHAR p_name2[] = { 0x4840, 0x3f3f, 0x4577, 0x446c, 0x3b6a, 0x45e4, 0x4824, 0 };
279static const WCHAR p_name3[] = { 0x4840, 0x3f3f, 0x4577, 0x446c, 0x3e6a, 0x44b2, 0x482f, 0 };
280static const WCHAR p_name4[] = { 0x3a8c, 0x47cb, 0x45b0, 0x45ec, 0x45a8, 0x4837, 0};
281static const WCHAR p_name5[] = { 0x4840, 0x4596, 0x3e6c, 0x45e4, 0x42e6, 0x421c, 0x4634, 0x4468, 0x4226, 0 };
282static const WCHAR p_name6[] = { 0x0005, 0x0053, 0x0075, 0x006d, 0x006d, 0x0061, 0x0072,
283 0x0079, 0x0049, 0x006e, 0x0066, 0x006f, 0x0072, 0x006d,
284 0x0061, 0x0074, 0x0069, 0x006f, 0x006e, 0 };
286static const WCHAR p_name7[] = { 0x0074, 0x0061, 0x0072, 0x0067, 0x0065, 0x0074, 0x0054, 0x006f, 0x0075, 0x0070,
287 0x0067, 0x0072, 0x0061, 0x0064, 0x0065, 0x0064, 0 };
288static const WCHAR p_name8[] = { 0x0023, 0x0074, 0x0061, 0x0072, 0x0067, 0x0065, 0x0074, 0x0054, 0x006f, 0x0075,
289 0x0070, 0x0067, 0x0072, 0x0061, 0x0064, 0x0065, 0x0064, 0 };
293 0x0001, 0x0001, 0x0001, 0x0001, 0x8001, 0x8002, 0x8003, 0x8004,
294 0x0002, 0x0003, 0x0004, 0x0005, 0xad00, 0xbd26, 0x8d00, 0x9502
300 "MsiPatchSequencePatchFamilyProductCodeSequenceAttributes1.1.19388.37230913B8D18FBB64CACA239C74C11E3FA74"
314 0x4d, 0x53, 0x43, 0x46, 0x00, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00,
315 0x00, 0x00, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x00, 0x00,
316 0x00, 0x00, 0x03, 0x01, 0x01, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
317 0x00, 0x00, 0x00, 0x5f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00,
318 0xea, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x87,
319 0x3c, 0xd4, 0xb8, 0x20, 0x00, 0x70, 0x61, 0x74, 0x63, 0x68, 0x2e,
320 0x74, 0x78, 0x74, 0x00, 0xe8, 0x03, 0x00, 0x00, 0xea, 0x03, 0x00,
321 0x00, 0x00, 0x00, 0xcb, 0x50, 0x17, 0x7e, 0x20, 0x00, 0x66, 0x69,
322 0x6c, 0x65, 0x2e, 0x74, 0x78, 0x74, 0x00, 0xb0, 0xb2, 0xb2, 0x25,
323 0x2d, 0x00, 0xd2, 0x07, 0x43, 0x4b, 0xcb, 0x2d, 0xce, 0x2c, 0x49,
324 0x2d, 0x2e, 0x89, 0x29, 0x48, 0x2c, 0x49, 0xce, 0x48, 0x4d, 0xd1,
325 0x2b, 0xa9, 0x28, 0x51, 0x18, 0x05, 0xa3, 0x60, 0x14, 0x0c, 0x37,
326 0x90, 0x8b, 0x9c, 0xd3, 0x41, 0xf9, 0x9c, 0x61, 0x14, 0x8c, 0x82,
327 0x51, 0x30, 0xdc, 0x00, 0x00
330 0x0007, 0x0000, 0x0006, 0x8000
333 0xfe, 0xff, 0x00, 0x00, 0x05, 0x02, 0x02, 0x00, 0x00, 0x00, 0x00,
334 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
335 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xe0, 0x85, 0x9f, 0xf2, 0xf9,
336 0x4f, 0x68, 0x10, 0xab, 0x91, 0x08, 0x00, 0x2b, 0x27, 0xb3, 0xd9,
337 0x30, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00,
338 0x00, 0x09, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x07, 0x00,
339 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x90,
340 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00,
341 0x0f, 0x00, 0x00, 0x00, 0xd8, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00,
342 0x00, 0x27, 0x00, 0x00, 0x00, 0x7b, 0x30, 0x46, 0x39, 0x36, 0x43,
343 0x44, 0x43, 0x30, 0x2d, 0x34, 0x43, 0x44, 0x46, 0x2d, 0x34, 0x33,
344 0x30, 0x34, 0x2d, 0x42, 0x32, 0x38, 0x33, 0x2d, 0x37, 0x42, 0x39,
345 0x32, 0x36, 0x34, 0x38, 0x38, 0x39, 0x45, 0x46, 0x37, 0x7d, 0x00,
346 0x00, 0x1e, 0x00, 0x00, 0x00, 0x27, 0x00, 0x00, 0x00, 0x7b, 0x39,
347 0x31, 0x33, 0x42, 0x38, 0x44, 0x31, 0x38, 0x2d, 0x46, 0x42, 0x42,
348 0x36, 0x2d, 0x34, 0x43, 0x41, 0x43, 0x2d, 0x41, 0x32, 0x33, 0x39,
349 0x2d, 0x43, 0x37, 0x34, 0x43, 0x31, 0x31, 0x45, 0x33, 0x46, 0x41,
350 0x37, 0x34, 0x7d, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x25, 0x00,
351 0x00, 0x00, 0x3a, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x54, 0x6f,
352 0x75, 0x70, 0x67, 0x72, 0x61, 0x64, 0x65, 0x64, 0x3b, 0x3a, 0x23,
353 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x54, 0x6f, 0x75, 0x70, 0x67,
354 0x72, 0x61, 0x64, 0x65, 0x64, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00,
355 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x50, 0x61, 0x74, 0x63, 0x68,
356 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x00,
357 0x03, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00
377static const WCHAR t1_name1[] = { 0x4840, 0x3f3f, 0x4577, 0x446c, 0x3b6a, 0x45e4, 0x4824, 0 };
378static const WCHAR t1_name2[] = { 0x4840, 0x3f3f, 0x4577, 0x446c, 0x3e6a, 0x44b2, 0x482f, 0 };
379static const WCHAR t1_name3[] = { 0x0005, 0x0053, 0x0075, 0x006d, 0x006d, 0x0061, 0x0072,
380 0x0079, 0x0049, 0x006e, 0x0066, 0x006f, 0x0072, 0x006d,
381 0x0061, 0x0074, 0x0069, 0x006f, 0x006e, 0 };
384 0x0008, 0x0001, 0x03ea, 0x8000
395 0xfe, 0xff, 0x00, 0x00, 0x05, 0x02, 0x02, 0x00, 0x00, 0x00, 0x00,
396 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
397 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xe0, 0x85, 0x9f, 0xf2, 0xf9,
398 0x4f, 0x68, 0x10, 0xab, 0x91, 0x08, 0x00, 0x2b, 0x27, 0xb3, 0xd9,
399 0x30, 0x00, 0x00, 0x00, 0x9f, 0x01, 0x00, 0x00, 0x0c, 0x00, 0x00,
400 0x00, 0x02, 0x00, 0x00, 0x00, 0x68, 0x00, 0x00, 0x00, 0x03, 0x00,
401 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xa8,
402 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0xb8, 0x00, 0x00, 0x00,
403 0x06, 0x00, 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00,
404 0x00, 0xd0, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0xdc, 0x00,
405 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0x00, 0x08,
406 0x00, 0x00, 0x00, 0xf7, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00,
407 0x07, 0x01, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x8f, 0x01, 0x00,
408 0x00, 0x10, 0x00, 0x00, 0x00, 0x97, 0x01, 0x00, 0x00, 0x1e, 0x00,
409 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, 0x49, 0x6e, 0x73, 0x74, 0x61,
410 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x44, 0x61, 0x74,
411 0x61, 0x62, 0x61, 0x73, 0x65, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00,
412 0x00, 0x16, 0x00, 0x00, 0x00, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6c,
413 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x44, 0x61, 0x74, 0x61,
414 0x62, 0x61, 0x73, 0x65, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00,
415 0x07, 0x00, 0x00, 0x00, 0x57, 0x69, 0x6e, 0x65, 0x48, 0x51, 0x00,
416 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
417 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
418 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
419 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
420 0x00, 0x1e, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x78, 0x38,
421 0x36, 0x3b, 0x31, 0x30, 0x33, 0x33, 0x00, 0x00, 0x00, 0x1e, 0x00,
422 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x3b, 0x31, 0x30, 0x33, 0x33,
423 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00,
424 0x7b, 0x39, 0x31, 0x33, 0x42, 0x38, 0x44, 0x31, 0x38, 0x2d, 0x46,
425 0x42, 0x42, 0x36, 0x2d, 0x34, 0x43, 0x41, 0x43, 0x2d, 0x41, 0x32,
426 0x33, 0x39, 0x2d, 0x43, 0x37, 0x34, 0x43, 0x31, 0x31, 0x45, 0x33,
427 0x46, 0x41, 0x37, 0x34, 0x7d, 0x31, 0x2e, 0x31, 0x2e, 0x31, 0x3b,
428 0x7b, 0x39, 0x31, 0x33, 0x42, 0x38, 0x44, 0x31, 0x38, 0x2d, 0x46,
429 0x42, 0x42, 0x36, 0x2d, 0x34, 0x43, 0x41, 0x43, 0x2d, 0x41, 0x32,
430 0x33, 0x39, 0x2d, 0x43, 0x37, 0x34, 0x43, 0x31, 0x31, 0x45, 0x33,
431 0x46, 0x41, 0x37, 0x34, 0x7d, 0x31, 0x2e, 0x31, 0x2e, 0x31, 0x3b,
432 0x7b, 0x41, 0x32, 0x45, 0x33, 0x44, 0x36, 0x34, 0x33, 0x2d, 0x34,
433 0x45, 0x32, 0x43, 0x2d, 0x34, 0x37, 0x37, 0x46, 0x2d, 0x41, 0x33,
434 0x30, 0x39, 0x2d, 0x46, 0x37, 0x36, 0x46, 0x35, 0x35, 0x32, 0x44,
435 0x35, 0x46, 0x34, 0x33, 0x7d, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
436 0x64, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x17, 0x00, 0x22,
449static const WCHAR t2_name2[] = { 0x4840, 0x3b3f, 0x43f2, 0x4438, 0x45b1, 0 };
450static const WCHAR t2_name3[] = { 0x4840, 0x3f7f, 0x4164, 0x422f, 0x4836, 0 };
451static const WCHAR t2_name4[] = { 0x4840, 0x4559, 0x44f2, 0x4568, 0x4737, 0 };
452static const WCHAR t2_name5[] = { 0x4840, 0x4119, 0x41b7, 0x3e6b, 0x41a4, 0x412e, 0x422a, 0 };
453static const WCHAR t2_name6[] = { 0x4840, 0x4452, 0x45f6, 0x43e4, 0x3baf, 0x423b, 0x4626,
454 0x4237, 0x421c, 0x4634, 0x4468, 0x4226, 0 };
455static const WCHAR t2_name7[] = { 0x4840, 0x3f3f, 0x4577, 0x446c, 0x3b6a, 0x45e4, 0x4824, 0 };
456static const WCHAR t2_name8[] = { 0x4840, 0x3f3f, 0x4577, 0x446c, 0x3e6a, 0x44b2, 0x482f, 0 };
457static const WCHAR t2_name9[] = { 0x0005, 0x0053, 0x0075, 0x006d, 0x006d, 0x0061, 0x0072,
458 0x0079, 0x0049, 0x006e, 0x0066, 0x006f, 0x0072, 0x006d,
459 0x0061, 0x0074, 0x0069, 0x006f, 0x006e, 0 };
460static const WCHAR t2_name10[] = { 0x4840, 0x420f, 0x45e4, 0x4578, 0x3b28, 0x4432, 0x44b3,
461 0x4231, 0x45f1, 0x4836, 0 };
462static const WCHAR t2_name11[] = { 0x4840, 0x448c, 0x44f0, 0x4472, 0x4468, 0x4837, 0 };
466 0x00c0, 0x0001, 0x9000, 0x83e8, 0x0801, 0x0002, 0x0003, 0x0002,
467 0x03e8, 0x8000, 0x0000, 0x0000, 0x9000, 0x83e9
470 0x0601, 0x8002, 0x03e9, 0x8000, 0x0000, 0x000d, 0x0000, 0x000e
473 0x0401, 0x000f, 0x0000, 0x0010, 0xad48, 0x0401, 0x000f, 0x0000,
474 0x0011, 0xa502, 0x0401, 0x000f, 0x0000, 0x0012, 0x8104, 0x0401,
475 0x000f, 0x0000, 0x0013, 0x8502, 0x0401, 0x000f, 0x0000, 0x0014,
476 0x9900, 0x0401, 0x000f, 0x0000, 0x0015, 0x9d48, 0x0401, 0x0016,
477 0x0000, 0x0017, 0xad26, 0x0401, 0x0016, 0x0000, 0x0018, 0x8502,
478 0x0401, 0x001a, 0x0000, 0x001b, 0xad26, 0x0401, 0x001a, 0x0000,
482 0x0101, 0x000f, 0x0101, 0x0016, 0x0101, 0x001a
485 0x0002, 0x0008, 0x0009, 0x0201, 0x000a, 0x000b
488 0x0201, 0x0019, 0x8002
491 0x0301, 0x000c, 0x0000, 0x87d1
494 "patch.txtfile.txtfile{327d9640-674f-4b9f-8b8a-547a0f6f8518}MSITESTDIRnewnew featurePATCHNEWSUMMARYSUBJECT"
495 "Installation DatabasePATCHNEWPACKAGECODE{42A14A82-12F8-4E6D-970E-1B4EE7BE28B0}PatchFiles#CAB_msitestprop"
496 "PatchFile_SequencePatchSizeAttributesHeaderStreamRef_PatchPackagePatchIdMedia_"
497 "{0F96CDC0-4CDF-4304-B283-7B9264889EF7}MsiPatchHeadersStreamRef"
531 0xfe, 0xff, 0x00, 0x00, 0x05, 0x02, 0x02, 0x00, 0x00, 0x00, 0x00,
532 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
533 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xe0, 0x85, 0x9f, 0xf2, 0xf9,
534 0x4f, 0x68, 0x10, 0xab, 0x91, 0x08, 0x00, 0x2b, 0x27, 0xb3, 0xd9,
535 0x30, 0x00, 0x00, 0x00, 0x5c, 0x01, 0x00, 0x00, 0x0b, 0x00, 0x00,
536 0x00, 0x02, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00,
537 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x78,
538 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00,
539 0x06, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00,
540 0x00, 0x9c, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0xa8, 0x00,
541 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0xb8, 0x00, 0x00, 0x00, 0x09,
542 0x00, 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00,
543 0x4c, 0x01, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x54, 0x01, 0x00,
544 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
545 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
546 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
547 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
548 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00,
549 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01,
550 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00,
551 0x06, 0x00, 0x00, 0x00, 0x3b, 0x31, 0x30, 0x33, 0x33, 0x00, 0x00,
552 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
553 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x7b,
554 0x39, 0x31, 0x33, 0x42, 0x38, 0x44, 0x31, 0x38, 0x2d, 0x46, 0x42,
555 0x42, 0x36, 0x2d, 0x34, 0x43, 0x41, 0x43, 0x2d, 0x41, 0x32, 0x33,
556 0x39, 0x2d, 0x43, 0x37, 0x34, 0x43, 0x31, 0x31, 0x45, 0x33, 0x46,
557 0x41, 0x37, 0x34, 0x7d, 0x31, 0x2e, 0x31, 0x2e, 0x31, 0x3b, 0x7b,
558 0x39, 0x31, 0x33, 0x42, 0x38, 0x44, 0x31, 0x38, 0x2d, 0x46, 0x42,
559 0x42, 0x36, 0x2d, 0x34, 0x43, 0x41, 0x43, 0x2d, 0x41, 0x32, 0x33,
560 0x39, 0x2d, 0x43, 0x37, 0x34, 0x43, 0x31, 0x31, 0x45, 0x33, 0x46,
561 0x41, 0x37, 0x34, 0x7d, 0x31, 0x2e, 0x31, 0x2e, 0x31, 0x3b, 0x7b,
562 0x41, 0x32, 0x45, 0x33, 0x44, 0x36, 0x34, 0x33, 0x2d, 0x34, 0x45,
563 0x32, 0x43, 0x2d, 0x34, 0x37, 0x37, 0x46, 0x2d, 0x41, 0x33, 0x30,
564 0x39, 0x2d, 0x46, 0x37, 0x36, 0x46, 0x35, 0x35, 0x32, 0x44, 0x35,
565 0x46, 0x34, 0x33, 0x7d, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x2d,
566 0x01, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x17, 0x00, 0x27, 0x09
569 0x0201, 0x0006, 0x0003
572 0x0601, 0x0003, 0x0004, 0x0005, 0x8000, 0x0000, 0x0002
575 0x0801, 0x0006, 0x0000, 0x0000, 0x0007, 0x8001, 0x8001, 0x0005,
601 for (
i = 0;
i < num_tables;
i++)
606 ok( 0,
"failed to create stream %#lx\n",
r );
612 ok( 0,
"failed to write stream\n" );
613 IStream_Release( stm );
625 const CLSID CLSID_MsiPatch = {0xc1086, 0, 0, {0xc0, 0, 0, 0, 0, 0, 0, 0x46}};
626 const CLSID CLSID_MsiTransform = {0xc1082, 0, 0, {0xc0, 0, 0, 0, 0, 0, 0, 0x46}};
634 ok(
r ==
S_OK,
"failed to create storage %#lx\n",
r );
638 r = IStorage_SetClass( stg, &CLSID_MsiPatch );
639 ok(
r ==
S_OK,
"failed to set storage type %#lx\n",
r );
643 r = IStorage_CreateStorage( stg,
p_name7,
mode, 0, 0, &stg1 );
644 ok(
r ==
S_OK,
"failed to create substorage %#lx\n",
r );
646 r = IStorage_SetClass( stg1, &CLSID_MsiTransform );
647 ok(
r ==
S_OK,
"failed to set storage type %#lx\n",
r );
650 IStorage_Release( stg1 );
652 r = IStorage_CreateStorage( stg,
p_name8,
mode, 0, 0, &stg2 );
653 ok(
r ==
S_OK,
"failed to create substorage %#lx\n",
r );
655 r = IStorage_SetClass( stg2, &CLSID_MsiTransform );
656 ok(
r ==
S_OK,
"failed to set storage type %#lx\n",
r );
659 IStorage_Release( stg2 );
660 IStorage_Release( stg );
674 skip(
"process is limited\n");
689 skip(
"Product installation failed with error code %u\n",
r);
694 ok(
size == 1000,
"expected 1000, got %lu\n",
size );
696 size =
sizeof(install_source);
698 "InstallSource", install_source, &
size );
709 ok( hdb,
"failed to get database handle\n" );
711 query =
"SELECT * FROM `Property` where `Property` = 'PATCHNEWPACKAGECODE'";
725 query =
"SELECT * FROM `Property` WHERE `Property` = 'PATCHNEWSUMMARYSUBJECT' "
726 "AND `Value` = 'Installer Database'";
744 ok( !
strcmp(
buffer,
"Installer Database" ),
"expected \'Installer Database\', got \'%s\'\n",
buffer );
753 ok(
size == 1002,
"expected 1002, got %lu\n",
size );
755 ok(
size == 1000,
"expected 1000, got %lu\n",
size );
762 ok( hdb,
"failed to get database handle\n" );
764 query =
"SELECT * FROM `Property` where `Property` = 'PATCHNEWPACKAGECODE'";
778 query =
"SELECT * FROM `Property` WHERE `Property` = 'PATCHNEWSUMMARYSUBJECT' "
779 "AND `Value` = 'Installation Database'";
797 ok( !
strcmp(
buffer,
"Installation Database" ),
"expected \'Installation Database\', got \'%s\'\n",
buffer );
890 static const char fmt[] =
"SELECT * FROM `%s` WHERE `Name` = '%s'";
992 static const char patchsource[] =
"MSPSRC0F96CDC04CDF4304B2837B9264889EF7";
1000 skip(
"process is limited\n");
1015 skip(
"Product installation failed with error code %d\n",
r);
1019 r =
MsiOpenProductA(
"{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}", &hproduct );
1023 ok( hdb,
"failed to get database handle\n" );
1025 r =
find_entry( hdb,
"_Streams",
"\5SummaryInformation" );
1028 query =
"SELECT * FROM `_Storages`";
1050 r =
find_entry( hdb,
"_Tables",
"FeatureComponents" );
1056 r =
find_entry( hdb,
"_Tables",
"InstallExecuteSequence" );
1062 r =
get_integer( hdb, 1,
"SELECT * FROM `Media` WHERE `VolumeLabel`=\'DISK1\'");
1063 ok(
r == 1,
"Got %u\n",
r );
1077 r =
MsiOpenProductA(
"{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}", &hproduct );
1081 ok( hdb,
"failed to get database handle\n" );
1083 r =
find_entry( hdb,
"_Streams",
"\5SummaryInformation" );
1086 r =
find_entryW( hdb,
L"_Streams",
L"\x3a8c\x47cb\x45b0\x45ec\x45a8\x4837" );
1089 query =
"SELECT * FROM `_Storages`";
1111 r =
find_entry( hdb,
"_Tables",
"FeatureComponents" );
1117 r =
find_entry( hdb,
"_Tables",
"InstallExecuteSequence" );
1126 r =
find_entry( hdb,
"_Tables",
"MsiPatchHeaders" );
1135 cr =
get_string( hdb, 6,
"SELECT * FROM `Media` WHERE `Source` IS NOT NULL");
1136 todo_wine ok( !
strcmp(cr, patchsource),
"Expected \"%s\", got \"%s\"\n", patchsource, cr );
1138 r =
get_integer( hdb, 1,
"SELECT * FROM `Media` WHERE `Source` IS NOT NULL");
1141 r =
get_integer( hdb, 2,
"SELECT * FROM `Media` WHERE `Source` IS NOT NULL");
1144 r =
get_integer( hdb, 1,
"SELECT * FROM `Media` WHERE `VolumeLabel`=\'DISK1\'");
1145 ok(
r == 1,
"Got %u\n",
r );
1147 cr =
get_string( hdb, 4,
"SELECT * FROM `Media` WHERE `Source` IS NOT NULL");
1148 ok( !
strcmp(cr,
"#CAB_msitest"),
"Expected \"#CAB_msitest\", got \"%s\"\n", cr );
1150 r =
get_integer( hdb, 8,
"SELECT * FROM `File` WHERE `File` = 'patch.txt'");
1151 ok(
r == 10000,
"Got %u\n",
r );
1177 skip(
"process is limited\n");
1192 skip(
"Product installation failed with error code %d\n",
r);
1202 "{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}",
1211 "{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}",
1219 "{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}",
1229 ok( !
strcmp( patch_code,
"{0F96CDC0-4CDF-4304-B283-7B9264889EF7}" ),
"wrong patch code\n" );
1247 "{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}",
static char CURR_DIR[MAX_PATH]
int strcmp(const char *String1, const char *String2)
ACPI_SIZE strlen(const char *String)
#define RegCloseKey(hKey)
LONG WINAPI RegOpenKeyA(HKEY hKey, LPCSTR lpSubKey, PHKEY phkResult)
LONG WINAPI RegQueryValueExA(_In_ HKEY hkeyorg, _In_ LPCSTR name, _In_ LPDWORD reserved, _Out_opt_ LPDWORD type, _Out_opt_ LPBYTE data, _Inout_opt_ LPDWORD count)
#define INVALID_HANDLE_VALUE
#define CreateFileA(a, b, c, d, e, f, g)
#define ERROR_NO_MORE_ITEMS
#define FILE_ATTRIBUTE_NORMAL
#define MultiByteToWideChar
static void cleanup(void)
BOOL WINAPI DeleteFileA(IN LPCSTR lpFileName)
BOOL WINAPI RemoveDirectoryA(IN LPCSTR lpPathName)
BOOL WINAPI CreateDirectoryA(IN LPCSTR lpPathName, IN LPSECURITY_ATTRIBUTES lpSecurityAttributes)
DWORD WINAPI GetFileSize(HANDLE hFile, LPDWORD lpFileSizeHigh)
BOOL WINAPI WriteFile(IN HANDLE hFile, IN LPCVOID lpBuffer, IN DWORD nNumberOfBytesToWrite OPTIONAL, OUT LPDWORD lpNumberOfBytesWritten, IN LPOVERLAPPED lpOverlapped OPTIONAL)
DWORD WINAPI GetCurrentDirectoryA(IN DWORD nBufferLength, OUT LPSTR lpBuffer)
BOOL WINAPI SetCurrentDirectoryA(IN LPCSTR lpPathName)
DWORD WINAPI GetTempPathA(IN DWORD nBufferLength, OUT LPSTR lpBuffer)
UINT WINAPI MsiDatabaseImportA(MSIHANDLE handle, const char *szFolder, const char *szFilename)
UINT WINAPI MsiOpenDatabaseW(LPCWSTR szDBPath, LPCWSTR szPersist, MSIHANDLE *phDB)
UINT WINAPI MsiCloseHandle(MSIHANDLE handle)
UINT WINAPI MsiOpenProductA(LPCSTR szProduct, MSIHANDLE *phProduct)
UINT WINAPI MsiGetPatchInfoExA(LPCSTR szPatchCode, LPCSTR szProductCode, LPCSTR szUserSid, MSIINSTALLCONTEXT dwContext, LPCSTR szProperty, LPSTR lpValue, DWORD *pcchValue)
UINT WINAPI MsiInstallProductA(LPCSTR szPackagePath, LPCSTR szCommandLine)
UINT WINAPI MsiGetProductInfoA(LPCSTR szProduct, LPCSTR szAttribute, LPSTR szBuffer, LPDWORD pcchValueBuf)
INSTALLUILEVEL WINAPI MsiSetInternalUI(INSTALLUILEVEL dwUILevel, HWND *phWnd)
UINT WINAPI MsiApplyPatchA(LPCSTR szPatchPackage, LPCSTR szInstallPackage, INSTALLTYPE eInstallType, LPCSTR szCommandLine)
UINT WINAPI MsiOpenPackageA(LPCSTR szPackage, MSIHANDLE *phPackage)
MSIHANDLE WINAPI MsiGetActiveDatabase(MSIHANDLE hInstall)
UINT WINAPI MsiGetPropertyA(MSIHANDLE hinst, const char *name, char *buf, DWORD *sz)
int WINAPI MsiRecordGetInteger(MSIHANDLE handle, UINT iField)
UINT WINAPI MsiRecordGetStringA(MSIHANDLE handle, UINT iField, char *szValue, DWORD *pcchValue)
UINT WINAPI MsiEnumPatchesExA(const char *szProductCode, const char *szUserSid, DWORD dwContext, DWORD dwFilter, DWORD dwIndex, char *szPatchCode, char *szTargetProductCode, MSIINSTALLCONTEXT *pdwTargetProductContext, char *szTargetUserSid, DWORD *pcchTargetUserSid)
UINT WINAPI MsiSummaryInfoSetPropertyA(MSIHANDLE handle, UINT uiProperty, UINT uiDataType, INT iValue, FILETIME *pftValue, const char *szValue)
UINT WINAPI MsiGetSummaryInformationA(MSIHANDLE hDatabase, const char *szDatabase, UINT uiUpdateCount, MSIHANDLE *pHandle)
UINT WINAPI MsiSummaryInfoPersist(MSIHANDLE handle)
HRESULT WINAPI StgCreateDocfile(LPCOLESTR pwcsName, DWORD grfMode, DWORD reserved, IStorage **ppstgOpen)
static BOOL is_process_elevated(void)
GLuint GLuint GLsizei count
GLuint GLuint GLsizei GLenum type
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLdouble GLdouble GLdouble r
GLenum GLuint GLenum GLsizei const GLchar * buf
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
static void write_tables(void)
#define sprintf(buf, format,...)
static const WCHAR filenameW[]
#define create_file(name, size)
void restart_as_admin_elevated(void)
BOOL delete_pf(const CHAR *rel_path, BOOL is_file)
char PROG_FILES_DIR[MAX_PATH]
char COMMON_FILES_DIR[MAX_PATH]
static const WCHAR t1_data0[]
static DWORD get_pf_file_size(const char *filename)
static const WCHAR t2_name12[]
static const char file_dat[]
static const WCHAR p_name6[]
static const WCHAR t2_data10[]
static void test_system_tables(void)
static const WCHAR t2_data4[]
static void set_suminfo(const WCHAR *filename)
static const WCHAR msifileW[]
static const WCHAR t2_data8[]
static const struct table_data table_transform1_data[]
static const WCHAR t2_data2[]
static const char media_dat[]
static const char p_data6[]
static const WCHAR p_data3[]
static const char p_data4[]
static const WCHAR t2_data11[]
static const WCHAR t1_name2[]
static void create_patch(const char *filename)
static const WCHAR p_data0[]
static BOOL get_program_files_dir(char *buf, char *buf2)
static const WCHAR t2_name11[]
static const char t2_data7[]
static const WCHAR t2_name7[]
static const WCHAR t2_name3[]
static const char property_dat[]
static const WCHAR p_data1[]
static const struct table_data table_transform2_data[]
static INT get_integer(MSIHANDLE hdb, UINT field, const char *query)
static const struct table_data table_patch_data[]
static const WCHAR t1_name3[]
static void write_file(const char *filename, const char *data, DWORD data_size)
static const char * mspfile
static const WCHAR p_name4[]
static const char p_data2[]
static const char condition_dat[]
static const WCHAR t2_name1[]
static const WCHAR t2_data3[]
static const WCHAR p_name5[]
static const WCHAR t2_name9[]
static const WCHAR mspfileW[]
static char * get_string(MSIHANDLE hdb, UINT field, const char *query)
static const WCHAR p_name8[]
static const WCHAR p_data5[]
static const WCHAR t2_data6[]
static const WCHAR t2_name10[]
static void create_database_suminfo(const char *filename, const struct msi_table *tables, UINT num_tables)
static const char * msifile
static const WCHAR t2_data5[]
static const char feature_dat[]
static const WCHAR p_name7[]
static void test_simple_patch(void)
static UINT find_entry(MSIHANDLE hdb, const char *table, const char *entry)
static const WCHAR t2_name4[]
static const char t1_data1[]
static const WCHAR p_name1[]
static const WCHAR p_name0[]
static const char install_exec_seq_dat[]
static const WCHAR t1_name1[]
static const WCHAR t2_name8[]
static const WCHAR t1_data2[]
static const char directory_dat[]
static void test_MsiOpenDatabase(void)
static const WCHAR t2_name6[]
static const WCHAR t2_name2[]
static const struct msi_table tables[]
static const WCHAR t2_name5[]
static const WCHAR t2_name0[]
static const char component_dat[]
static const char t1_data3[]
static const char feature_comp_dat[]
static const WCHAR t2_data1[]
static const WCHAR p_name2[]
static void test_patch_registration(void)
static const char t2_data9[]
static const WCHAR p_name3[]
static const WCHAR t1_name0[]
static const WCHAR t2_data0[]
static UINT find_entryW(MSIHANDLE hdb, const WCHAR *table, const WCHAR *entry)
static const WCHAR t2_data12[]
INTERNETFEATURELIST feature
#define INSTALLPROPERTY_LOCALPACKAGEA
@ MSIINSTALLCONTEXT_MACHINE
@ MSIINSTALLCONTEXT_USERUNMANAGED
@ MSIINSTALLCONTEXT_USERMANAGED
UINT WINAPI MsiViewClose(MSIHANDLE hView)
UINT WINAPI MsiViewExecute(MSIHANDLE hView, MSIHANDLE hRec)
UINT WINAPI MsiDatabaseOpenViewW(MSIHANDLE hdb, LPCWSTR szQuery, MSIHANDLE *phView)
UINT WINAPI MsiDatabaseCommit(MSIHANDLE hdb)
UINT WINAPI MsiDatabaseOpenViewA(MSIHANDLE hdb, const char *szQuery, MSIHANDLE *phView)
UINT WINAPI MsiViewFetch(MSIHANDLE hView, MSIHANDLE *record)
#define MSIDBOPEN_PATCHFILE
#define MSIDBOPEN_READONLY
#define STGM_SHARE_EXCLUSIVE
#define INVALID_FILE_SIZE
#define ERROR_UNKNOWN_PRODUCT
#define ERROR_OPEN_FAILED
#define HKEY_LOCAL_MACHINE
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)