Merge xmrig v6.15.2 into master
This commit is contained in:
commit
349303201a
13 changed files with 243 additions and 53 deletions
|
@ -143,17 +143,10 @@ xmrig::String xmrig::Env::get(const String &name, const std::map<String, String>
|
|||
xmrig::String xmrig::Env::hostname()
|
||||
{
|
||||
char buf[UV_MAXHOSTNAMESIZE]{};
|
||||
size_t size = sizeof(buf);
|
||||
|
||||
# if UV_VERSION_HEX >= 0x010c00
|
||||
if (uv_os_gethostname(buf, &size) == 0) {
|
||||
if (gethostname(buf, sizeof(buf)) == 0) {
|
||||
return static_cast<const char *>(buf);
|
||||
}
|
||||
# else
|
||||
if (gethostname(buf, size) == 0) {
|
||||
return static_cast<const char *>(buf);
|
||||
}
|
||||
# endif
|
||||
|
||||
return {};
|
||||
}
|
||||
|
|
|
@ -141,7 +141,7 @@ xmrig::Entry::Id xmrig::Entry::get(const Process &process)
|
|||
return Usage;
|
||||
}
|
||||
|
||||
if (args.hasArg("-V") || args.hasArg("--version")) {
|
||||
if (args.hasArg("-V") || args.hasArg("--version") || args.hasArg("--versions")) {
|
||||
return Version;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue