MCPcopy Create free account
hub / github.com/BeneficialCode/WinArk / ChangeValueCommand

Method ChangeValueCommand

WinArk/ChangeValueCommand.cpp:5–11  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3#include "Registry.h"
4
5ChangeValueCommand::ChangeValueCommand(PCWSTR path, PCWSTR name, DWORD type, const PVOID data,
6 LONG size, AppCommandCallback<ChangeValueCommand> cb)
7 :RegAppCommandBase(L"Change Value"+CString(name),path,name,cb),
8 _type(type),_size(size){
9 _data = std::make_unique<BYTE[]>(size);
10 memcpy(_data.get(), data, size);
11}
12
13bool ChangeValueCommand::Execute() {
14 auto key = Registry::OpenKey(GetPath(), KEY_SET_VALUE | KEY_QUERY_VALUE);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected