Skip to content

Commit

Permalink
replace *int_least* by *int* types
Browse files Browse the repository at this point in the history
  • Loading branch information
gammasoft71 committed Jul 31, 2024
1 parent 31af269 commit 765dddc
Show file tree
Hide file tree
Showing 211 changed files with 1,872 additions and 1,872 deletions.
30 changes: 15 additions & 15 deletions docs/types.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/xtd.core.native.linux/include/xtd/native/linux/mutex.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

inline static const pthread_mutex_t* MUTEX_FAILED = reinterpret_cast<pthread_mutex_t *>(-1);

static inline int pthread_mutex_milliseconds_timedlock(pthread_mutex_t* mut, int_least32_t milliseconds_timeout) {
static inline int pthread_mutex_milliseconds_timedlock(pthread_mutex_t* mut, int32_t milliseconds_timeout) {
struct timespec timeout;
clock_gettime(CLOCK_REALTIME, &timeout);
timeout.tv_sec += milliseconds_timeout / 1000;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

inline static constexpr size_t PSEMNAMLEN = 31;

static inline int sem_milliseconds_timedwait(sem_t *sem, int_least32_t milliseconds_timeout) {
static inline int sem_milliseconds_timedwait(sem_t *sem, int32_t milliseconds_timeout) {
struct timespec timeout;
clock_gettime(CLOCK_REALTIME, &timeout);
timeout.tv_sec += milliseconds_timeout / 1000;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ namespace xtd::native::linux {
return result;
}

static bool try_parse(const std::string& str, int_least32_t& value) noexcept {
static bool try_parse(const std::string& str, int32_t& value) noexcept {
try {
value = std::atoi(str.c_str());
return true;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ void condition_variable::pulse_all(intmax_t handle) {
pthread_cond_broadcast(reinterpret_cast<pthread_cond_t*>(handle));
}

bool condition_variable::wait(intmax_t handle, intmax_t critical_section_handle, int_least32_t milliseconds_timeout) {
bool condition_variable::wait(intmax_t handle, intmax_t critical_section_handle, int32_t milliseconds_timeout) {
if (handle == reinterpret_cast<intmax_t>(MUTEX_FAILED)) return false;
if (reinterpret_cast<pthread_mutex_t*>(critical_section_handle) == nullptr) return false;

Expand Down
112 changes: 56 additions & 56 deletions src/xtd.core.native.linux/src/xtd/native/linux/console.cpp

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
using namespace std;
using namespace xtd::native;

vector<uint_least8_t> cryptography::machine_guid() {
vector<uint8_t> cryptography::machine_guid() {
static auto guid_str = linux::shell_execute::run("{ uname -n ; cat /proc/meminfo | head -n1 ; cat /proc/cpuinfo ; } | md5sum");

static const auto guid_fallback = string {"30395f0ed6aa4a5eb4af6f90a608c605"};
Expand All @@ -17,8 +17,8 @@ vector<uint_least8_t> cryptography::machine_guid() {
if (hex_chars.find(static_cast<char>(toupper(guid_str[index]))) == hex_chars.npos) guid_str.erase(index--, 1);
if (guid_str.size() != 32) guid_str = guid_fallback;

auto bytes = vector<uint_least8_t> {};
auto bytes = vector<uint8_t> {};
for (auto index = 0u; index < guid_str.size(); index += 2)
bytes.push_back(static_cast<uint_least8_t>(stoi(guid_str.substr(index, 2), 0, 16)));
bytes.push_back(static_cast<uint8_t>(stoi(guid_str.substr(index, 2), 0, 16)));
return bytes;
}
4 changes: 2 additions & 2 deletions src/xtd.core.native.linux/src/xtd/native/linux/date_time.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ using namespace std;
using namespace xtd::native;

namespace {
static const int_least64_t ticks_per_second = 10000000;
static const int64_t ticks_per_second = 10000000;

/* Generate by this c# code source :
Expand Down Expand Up @@ -240,7 +240,7 @@ date_time::time_zone_info date_time::get_local_time_zone() {
if (iterator != stzis.end()) {
local_time_zone = *iterator;
local_time_zone.id = reinterpret_cast<const char*>(tzname[0]);
local_time_zone.base_utc_offset = static_cast<int_least64_t>(-timezone * ticks_per_second);
local_time_zone.base_utc_offset = static_cast<int64_t>(-timezone * ticks_per_second);
local_time_zone.daylight_name = reinterpret_cast<const char*>(tzname[1]);
local_time_zone.display_name = string_printf("(UTC%s%02d:%02d) %s", (-timezone) ? "+" : "", abs(timezone) / 3600, (abs(timezone) % 3600) / 60, reinterpret_cast<const char*>(tzname[0]));
local_time_zone.standard_name = reinterpret_cast<const char*>(tzname[0]);
Expand Down
4 changes: 2 additions & 2 deletions src/xtd.core.native.linux/src/xtd/native/linux/debugger.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ bool debugger::launch() {
return true;
}

int_least32_t debugger::show_assert_dialog(const std::string& text, const std::string& caption) {
int32_t debugger::show_assert_dialog(const std::string& text, const std::string& caption) {
gtk_init_check(0, nullptr);
auto dialog = gtk_message_dialog_new(nullptr, GtkDialogFlags::GTK_DIALOG_MODAL, GtkMessageType::GTK_MESSAGE_ERROR, GtkButtonsType::GTK_BUTTONS_NONE, "%s", text.c_str());
gtk_window_set_title(GTK_WINDOW(dialog), caption.c_str());
Expand All @@ -57,7 +57,7 @@ int_least32_t debugger::show_assert_dialog(const std::string& text, const std::s
return return_code == GTK_RESPONSE_YES ? ADR_ABORT : (return_code == GTK_RESPONSE_NO ? ADR_RETRY : ADR_IGNORE);
}

void debugger::log(int_least32_t level, const std::string& category, const std::string& message) {
void debugger::log(int32_t level, const std::string& category, const std::string& message) {
syslog(LOG_EMERG | LOG_USER, "%s", message.c_str());
std::cerr << message << std::flush;
}
Expand Down
12 changes: 6 additions & 6 deletions src/xtd.core.native.linux/src/xtd/native/linux/directory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ directory::directory_iterator& directory::directory_iterator::operator ++() {
return *this;
}

directory::directory_iterator directory::directory_iterator::operator ++(int_least32_t) {
directory::directory_iterator directory::directory_iterator::operator ++(int32_t) {
auto result = *this;
++(*this);
return result;
Expand Down Expand Up @@ -130,7 +130,7 @@ directory::file_iterator& directory::file_iterator::operator ++() {
return *this;
}

directory::file_iterator directory::file_iterator::operator ++(int_least32_t) {
directory::file_iterator directory::file_iterator::operator ++(int32_t) {
auto result = *this;
++(*this);
return result;
Expand Down Expand Up @@ -200,7 +200,7 @@ directory::file_and_directory_iterator& directory::file_and_directory_iterator::
return *this;
}

directory::file_and_directory_iterator directory::file_and_directory_iterator::operator ++(int_least32_t) {
directory::file_and_directory_iterator directory::file_and_directory_iterator::operator ++(int32_t) {
auto result = *this;
++(*this);
return result;
Expand Down Expand Up @@ -231,7 +231,7 @@ const std::string& directory::file_and_directory_iterator::pattern() const {
return data_->pattern_;
}

int_least32_t directory::create(const std::string& directory_name) {
int32_t directory::create(const std::string& directory_name) {
return mkdir(directory_name.c_str(), S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IWGRP | S_IXGRP | S_IROTH | S_IWOTH | S_IXOTH);
}

Expand Down Expand Up @@ -260,10 +260,10 @@ string directory::get_current_directory() {
return result ? path : "";
}

int_least32_t directory::remove(const std::string& directory_name) {
int32_t directory::remove(const std::string& directory_name) {
return rmdir(directory_name.c_str());
}

int_least32_t directory::set_current_directory(const std::string& directory_name) {
int32_t directory::set_current_directory(const std::string& directory_name) {
return chdir(directory_name.c_str());
}
12 changes: 6 additions & 6 deletions src/xtd.core.native.linux/src/xtd/native/linux/dns.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ void dns::destroy(intmax_t host) {
delete reinterpret_cast<hostent*>(host);
}

intmax_t dns::get_host_by_address(const string& host_address, int_least32_t host_address_type) {
intmax_t dns::get_host_by_address(const string& host_address, int32_t host_address_type) {
auto lock = lock_guard<mutex> {dns_mutex};
int_least64_t internet_address = 0;
int64_t internet_address = 0;
inet_pton(host_address_type, host_address.c_str(), &internet_address);
hostent* host = gethostbyaddr(reinterpret_cast<char*>(&internet_address), host_address_type == ADDRESS_FAMILY_INTER_NETWORK ? 4 : 16, host_address_type);
if (host == nullptr) return 0;
Expand All @@ -50,11 +50,11 @@ vector<string> dns::get_aliases(intmax_t host) {
return aliases;
}

vector<vector<uint_least8_t>> dns::get_addresses(intmax_t host) {
auto addresses = vector<vector<uint_least8_t>> {};
vector<vector<uint8_t>> dns::get_addresses(intmax_t host) {
auto addresses = vector<vector<uint8_t>> {};
auto index = size_t {0};
while (reinterpret_cast<hostent*>(host)->h_addr_list[index] != nullptr) {
addresses.emplace_back(reinterpret_cast<const uint_least8_t*>(reinterpret_cast<hostent*>(host)->h_addr_list[index]), reinterpret_cast<const uint_least8_t*>(reinterpret_cast<hostent*>(host)->h_addr_list[index]) + (reinterpret_cast<hostent*>(host)->h_addrtype == ADDRESS_FAMILY_INTER_NETWORK ? 4 : 16));
addresses.emplace_back(reinterpret_cast<const uint8_t*>(reinterpret_cast<hostent*>(host)->h_addr_list[index]), reinterpret_cast<const uint8_t*>(reinterpret_cast<hostent*>(host)->h_addr_list[index]) + (reinterpret_cast<hostent*>(host)->h_addrtype == ADDRESS_FAMILY_INTER_NETWORK ? 4 : 16));
index++;
}
return addresses;
Expand All @@ -64,7 +64,7 @@ string dns::get_host_name(intmax_t host) {
return reinterpret_cast<hostent*>(host)->h_name;
}

int_least32_t dns::get_host_name(string& host_name) {
int32_t dns::get_host_name(string& host_name) {
char name[1024];
auto result = gethostname(name, 1024);
host_name = name;
Expand Down
4 changes: 2 additions & 2 deletions src/xtd.core.native.linux/src/xtd/native/linux/drive.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ bool drive::get_available_free_space(const std::string& root_path_name, size_t&
return true;
}

int_least32_t drive::get_drive_type(const std::string& root_path_name) {
int32_t drive::get_drive_type(const std::string& root_path_name) {
if (root_drive == root_path_name) return DRIVE_FIXED;
if (find(ram_drives.begin(), ram_drives.end(), root_path_name) != ram_drives.end()) return DRIVE_RAMDISK;
if (find(network_drives.begin(), network_drives.end(), root_path_name) != network_drives.end()) return DRIVE_REMOTE;
Expand Down Expand Up @@ -84,7 +84,7 @@ bool drive::get_volume_information(const std::string& root_path_name, std::strin
return false;

volume_name = root_path_name;
static auto file_system_names = map<uint_least32_t, string> {{0x0000adf5, "adfs"}, {0x0000adff, "adfs"}, {0x42465331, "befs"}, {0x1BADFACE, "bfs"}, {0xFF534D42, "cifs"}, {0x73757245, "coda"}, {0x012FF7B7, "coh"}, {0x28cd3d45, "cramfs"}, {0x00001373, "devfs"}, {0x00414A53, "efs"}, {0x0000137D, "ext"}, {0x0000EF51, "ext2"}, {0x0000EF52, "ext3"}, {0x0000EF53, "ext4"}, {0x00004244, "hfs"}, {0xF995E849, "hpfs"}, {0x958458f6, "hgfs"}, {0x00009660, "isofs"}, {0x000072b6, "jffs2"}, {0x3153464a, "jfs"}, {0x0000137F, "minix"}, {0x0000138F, "minix"}, {0x00002468, "minix2"}, {0x00002478, "minix2"}, {0x00004d44, "fat32"}, {0x0000564c, "ncp"}, {0x00006969, "nfs"}, {0x5346544e, "ntfs"}, {0x00009fa1, "openprom"}, {0x00009fa0, "proc"}, {0x0000002f, "qnx4"}, {0x52654973, "reiserfs"}, {0x00007275, "romfs"}, {0x0000517B, "smb"}, {0x012FF7B6, "sysv2"}, {0x012FF7B5, "sysv4"}, {0x01021994, "tmpfs"}, {0x15013346, "udf"}, {0x00011954, "ufs"}, {0x00009fa2, "usb device"}, {0xa501FCF5, "vxfs"}, {0x012FF7B4, "xenix"}, {0x58465342, "xfs"}, {0x012FD16D, "_xiafs"}};
static auto file_system_names = map<uint32_t, string> {{0x0000adf5, "adfs"}, {0x0000adff, "adfs"}, {0x42465331, "befs"}, {0x1BADFACE, "bfs"}, {0xFF534D42, "cifs"}, {0x73757245, "coda"}, {0x012FF7B7, "coh"}, {0x28cd3d45, "cramfs"}, {0x00001373, "devfs"}, {0x00414A53, "efs"}, {0x0000137D, "ext"}, {0x0000EF51, "ext2"}, {0x0000EF52, "ext3"}, {0x0000EF53, "ext4"}, {0x00004244, "hfs"}, {0xF995E849, "hpfs"}, {0x958458f6, "hgfs"}, {0x00009660, "isofs"}, {0x000072b6, "jffs2"}, {0x3153464a, "jfs"}, {0x0000137F, "minix"}, {0x0000138F, "minix"}, {0x00002468, "minix2"}, {0x00002478, "minix2"}, {0x00004d44, "fat32"}, {0x0000564c, "ncp"}, {0x00006969, "nfs"}, {0x5346544e, "ntfs"}, {0x00009fa1, "openprom"}, {0x00009fa0, "proc"}, {0x0000002f, "qnx4"}, {0x52654973, "reiserfs"}, {0x00007275, "romfs"}, {0x0000517B, "smb"}, {0x012FF7B6, "sysv2"}, {0x012FF7B5, "sysv4"}, {0x01021994, "tmpfs"}, {0x15013346, "udf"}, {0x00011954, "ufs"}, {0x00009fa2, "usb device"}, {0xa501FCF5, "vxfs"}, {0x012FF7B4, "xenix"}, {0x58465342, "xfs"}, {0x012FD16D, "_xiafs"}};
auto it = file_system_names.find(stat.f_type);
file_system_name = it == file_system_names.end() ? "unknown" : it->second;
return true;
Expand Down
32 changes: 16 additions & 16 deletions src/xtd.core.native.linux/src/xtd/native/linux/environment.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ using namespace std::literals;
using namespace xtd::native;

extern char** environ;
int_least32_t __environment_argc = 0;
int32_t __environment_argc = 0;
char** __environment_argv;

namespace {
__attribute__((constructor)) void startup_program(int_least32_t argc, char** argv) {
__attribute__((constructor)) void startup_program(int32_t argc, char** argv) {
__environment_argc = argc;
__environment_argv = argv;
}
Expand All @@ -43,7 +43,7 @@ namespace {
}
}

int_least32_t environment::at_quick_exit(void (*on_quick_exit)(void)) {
int32_t environment::at_quick_exit(void (*on_quick_exit)(void)) {
return std::at_quick_exit(on_quick_exit);
}

Expand Down Expand Up @@ -112,7 +112,7 @@ string environment::get_distribution_name() {
return name_it->second;
}

void environment::get_distribution_version(int_least32_t& major, int_least32_t& minor, int_least32_t& build, int_least32_t& revision) {
void environment::get_distribution_version(int32_t& major, int32_t& minor, int32_t& build, int32_t& revision) {
auto name_it = get_distribution_key_values().find("VERSION_ID");
if (name_it == get_distribution_key_values().end()) return;
auto versions = xtd::native::linux::strings::split(name_it->second, {'.'});
Expand All @@ -126,7 +126,7 @@ string environment::get_distribution_version_string() {
return iterator->second;
}

string environment::get_environment_variable(const string& variable, int_least32_t target) {
string environment::get_environment_variable(const string& variable, int32_t target) {
if (target == ENVIRONMENT_VARIABLE_TARGET_PROCESS) {
auto value = getenv(variable.c_str());
return value ? value : "";
Expand All @@ -140,7 +140,7 @@ string environment::get_environment_variable(const string& variable, int_least32
return "";
}

map<string, string>& environment::get_environment_variables(int_least32_t target) {
map<string, string>& environment::get_environment_variables(int32_t target) {
if (target == ENVIRONMENT_VARIABLE_TARGET_PROCESS) {
static auto envs = map<string, string> {};
if (envs.size() == 0) {
Expand All @@ -166,8 +166,8 @@ map<string, string>& environment::get_environment_variables(int_least32_t target
return envs;
}

string environment::get_know_folder_path(int_least32_t csidl) {
static auto special_folders = map<int_least32_t, string> {{CSIDL_DESKTOP, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Desktop"}, {CSIDL_PERSONAL, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS)}, {CSIDL_MYMUSIC, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Music"}, {CSIDL_MYVIDEO, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Videos"}, {CSIDL_DESKTOPDIRECTORY, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Desktop"}, {CSIDL_FONTS, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/.fonts"}, {CSIDL_TEMPLATES, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Templates"}, {CSIDL_APPDATA, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/.config"}, {CSIDL_LOCAL_APPDATA, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/.local/share"}, {CSIDL_COMMON_APPDATA, "/usr/share"}, {CSIDL_MYPICTURES, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Pictures"}, {CSIDL_PROFILE, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS)}, {CSIDL_COMMON_TEMPLATES, "/usr/share/templates"}, {CSIDL_HOME, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS)}};
string environment::get_know_folder_path(int32_t csidl) {
static auto special_folders = map<int32_t, string> {{CSIDL_DESKTOP, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Desktop"}, {CSIDL_PERSONAL, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS)}, {CSIDL_MYMUSIC, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Music"}, {CSIDL_MYVIDEO, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Videos"}, {CSIDL_DESKTOPDIRECTORY, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Desktop"}, {CSIDL_FONTS, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/.fonts"}, {CSIDL_TEMPLATES, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Templates"}, {CSIDL_APPDATA, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/.config"}, {CSIDL_LOCAL_APPDATA, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/.local/share"}, {CSIDL_COMMON_APPDATA, "/usr/share"}, {CSIDL_MYPICTURES, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS) + "/Pictures"}, {CSIDL_PROFILE, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS)}, {CSIDL_COMMON_TEMPLATES, "/usr/share/templates"}, {CSIDL_HOME, get_environment_variable("HOME", ENVIRONMENT_VARIABLE_TARGET_PROCESS)}};
auto it = special_folders.find(csidl);
if (it == special_folders.end()) return "";
return it->second;
Expand All @@ -177,7 +177,7 @@ string environment::get_machine_name() {
return linux::strings::replace(linux::shell_execute::run("uname", "-n"), "\n", "");
}

int_least32_t environment::get_os_platform_id() {
int32_t environment::get_os_platform_id() {
#if defined(__ANDROID__)
return PLATFORM_ANDROID;
#else
Expand All @@ -186,15 +186,15 @@ int_least32_t environment::get_os_platform_id() {
#endif
}

void environment::get_os_version(int_least32_t& major, int_least32_t& minor, int_least32_t& build, int_least32_t& revision) {
void environment::get_os_version(int32_t& major, int32_t& minor, int32_t& build, int32_t& revision) {
auto numbers = linux::strings::split(linux::shell_execute::run("uname", "-r"), {'.', '-', '\n'});
if (numbers.size() < 1 || !linux::strings::try_parse(numbers[0], major)) major = 0;
if (numbers.size() < 2 || !linux::strings::try_parse(numbers[1], minor)) minor = 0;
if (numbers.size() < 3 || !linux::strings::try_parse(numbers[2], build)) build = 0;
if (numbers.size() < 4 || !linux::strings::try_parse(numbers[3], revision)) revision = 0;
}

uint_least32_t environment::get_processor_count() {
uint32_t environment::get_processor_count() {
return thread::hardware_concurrency();
}

Expand All @@ -212,7 +212,7 @@ size_t environment::get_system_page_size() {
return sysconf(_SC_PAGESIZE);
}

uint_least32_t environment::get_tick_count() {
uint32_t environment::get_tick_count() {
// https://stackoverflow.com/questions/1540627/what-api-do-i-call-to-get-the-system-uptime
using struct_sysinfo = struct sysinfo;
auto info = struct_sysinfo {};
Expand Down Expand Up @@ -253,11 +253,11 @@ string environment::new_line() {
return "\n";
}

void environment::quick_exit(int_least32_t exit_code) noexcept {
void environment::quick_exit(int32_t exit_code) noexcept {
std::quick_exit(exit_code);
}

void environment::set_environment_variable(const string& name, const string& value, int_least32_t target) {
void environment::set_environment_variable(const string& name, const string& value, int32_t target) {
if (target == ENVIRONMENT_VARIABLE_TARGET_PROCESS)
setenv(name.c_str(), value.c_str(), 1);
else if (target == ENVIRONMENT_VARIABLE_TARGET_USER) {
Expand All @@ -267,7 +267,7 @@ void environment::set_environment_variable(const string& name, const string& val
}
}

void environment::unset_environment_variable(const string& name, int_least32_t target) {
void environment::unset_environment_variable(const string& name, int32_t target) {
if (target == ENVIRONMENT_VARIABLE_TARGET_PROCESS)
unsetenv(name.c_str());
else if (target == ENVIRONMENT_VARIABLE_TARGET_USER) {
Expand All @@ -277,6 +277,6 @@ void environment::unset_environment_variable(const string& name, int_least32_t t
}
}

int_least64_t environment::working_set() {
int64_t environment::working_set() {
return 0;
}
Loading

0 comments on commit 765dddc

Please sign in to comment.