Skip to content

Use correct constant to read 64bit registry #37

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion Win32.xs
Original file line number Diff line number Diff line change
Expand Up @@ -1667,6 +1667,10 @@ XS(w32_GetProcessPrivileges)
XSRETURN(1);
}

#ifndef RRF_SUBKEY_WOW6464KEY
# define RRF_SUBKEY_WOW6464KEY 0x00010000
#endif
Comment on lines +1670 to +1672
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please move the preprocessor definitions to the top of the file, where all the other constants are defined? Thanks!


XS(w32_IsDeveloperModeEnabled)
{
dXSARGS;
Expand All @@ -1693,7 +1697,7 @@ XS(w32_IsDeveloperModeEnabled)
HKEY_LOCAL_MACHINE,
"SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\AppModelUnlock",
"AllowDevelopmentWithoutDevLicense",
RRF_RT_REG_DWORD | KEY_WOW64_64KEY,
RRF_RT_REG_DWORD | RRF_SUBKEY_WOW6464KEY,
NULL,
&val,
&val_size
Expand Down