diff --git a/src/gui/Core/hiperiso_util.c b/src/gui/Core/hiperiso_util.c index d8fc90c..b2831e9 100644 --- a/src/gui/Core/hiperiso_util.c +++ b/src/gui/Core/hiperiso_util.c @@ -383,8 +383,6 @@ int hiperiso_fill_gpt(uint64_t size, uint64_t reserve, int align4k, HISO_GPT_INF HISO_GPT_HDR *Head = &gpt->Head; HISO_GPT_PART_TBL *Table = gpt->PartTbl; hiperiso_guid WindowsDataPartType = { 0xebd0a0a2, 0xb9e5, 0x4433, { 0x87, 0xc0, 0x68, 0xb6, 0xb7, 0x26, 0x99, 0xc7 } }; - //hiperiso_guid EspPartType = { 0xc12a7328, 0xf81f, 0x11d2, { 0xba, 0x4b, 0x00, 0xa0, 0xc9, 0x3e, 0xc9, 0x3b } }; - //hiperiso_guid BiosGrubPartType = { 0x21686148, 0x6449, 0x6e6f, { 0x74, 0x4e, 0x65, 0x65, 0x64, 0x45, 0x46, 0x49 } }; HiperisoFillProtectMBR(size, &gpt->MBR); @@ -436,8 +434,7 @@ int hiperiso_fill_gpt(uint64_t size, uint64_t reserve, int align4k, HISO_GPT_INF Table[0].Attr = 0; hiperiso_fill_gpt_partname(Table[0].Name, "Hiperiso"); - // to fix windows issue - //memcpy(&(Table[1].PartType), &EspPartType, sizeof(GUID)); + // Use msftdata for partition 2 (Ventoy-compatible: both partitions visible + boots) memcpy(&(Table[1].PartType), &WindowsDataPartType, sizeof(hiperiso_guid)); hiperiso_gen_preudo_uuid(&(Table[1].PartGuid)); Table[1].StartLBA = Table[0].LastLBA + 1; diff --git a/src/gui/Web/hiperiso_http.c b/src/gui/Web/hiperiso_http.c index bf3444a..6a79b72 100644 --- a/src/gui/Web/hiperiso_http.c +++ b/src/gui/Web/hiperiso_http.c @@ -46,7 +46,7 @@ static int g_pub_out_max = 0; static pthread_mutex_t g_api_mutex; static char g_cur_language[128]; -static int g_cur_part_style = 0; +static int g_cur_part_style = 1; static int g_cur_show_all = 0; static char g_cur_server_token[64]; static struct mg_context *g_hiperiso_http_ctx = NULL; diff --git a/src/hisocli/hisogpt.c b/src/hisocli/hisogpt.c index d903309..ebd6a95 100644 --- a/src/hisocli/hisogpt.c +++ b/src/hisocli/hisogpt.c @@ -189,7 +189,7 @@ int hisogpt_main(int argc, char **argv) read(fd, pBackGptInfo, sizeof(HISO_BK_GPT_INFO)); Name = pMainGptInfo->PartTbl[1].Name; - if (Name[0] == 'V' && Name[1] == 'T' && Name[2] == 'O' && Name[3] == 'Y') + if (Name[0] == 'H' && Name[1] == 'I' && Name[2] == 'S' && Name[3] == 'O') { if (pMainGptInfo->PartTbl[1].Attr != HIPERISO_EFI_PART_ATTR) { diff --git a/src/hisocli/partresize.c b/src/hisocli/partresize.c index 8e5491b..ce55d94 100644 --- a/src/hisocli/partresize.c +++ b/src/hisocli/partresize.c @@ -590,7 +590,6 @@ static int update_part_table(char *disk, UINT64 part2start) memcpy(PartTbl + (j + 1), PartTbl + j, sizeof(HISO_GPT_PART_TBL)); } - // to fix windows issue memset(PartTbl + 1, 0, sizeof(HISO_GPT_PART_TBL)); memcpy(&(PartTbl[1].PartType), &g_WindowsDataPartGuid, sizeof(GUID)); hiperiso_gen_preudo_uuid(&(PartTbl[1].PartGuid)); @@ -600,10 +599,10 @@ static int update_part_table(char *disk, UINT64 part2start) PartTbl[1].StartLBA = PartTbl[0].LastLBA + 1; PartTbl[1].LastLBA = PartTbl[1].StartLBA + HIPERISO_EFI_PART_SIZE / 512 - 1; PartTbl[1].Attr = HIPERISO_EFI_PART_ATTR; - PartTbl[1].Name[0] = 'V'; - PartTbl[1].Name[1] = 'T'; - PartTbl[1].Name[2] = 'O'; - PartTbl[1].Name[3] = 'Y'; + PartTbl[1].Name[0] = 'H'; + PartTbl[1].Name[1] = 'I'; + PartTbl[1].Name[2] = 'S'; + PartTbl[1].Name[3] = 'O'; PartTbl[1].Name[4] = 'E'; PartTbl[1].Name[5] = 'F'; PartTbl[1].Name[6] = 'I';