rgbd
src
utility.cpp
Go to the documentation of this file.
1
#include "
rgbd/utility.h
"
2
3
#include <ros/console.h>
4
5
#include <
exception
>
6
#include <limits.h>
7
#include <unistd.h>
8
9
10
namespace
rgbd
11
{
12
13
std::string
get_hostname
()
14
{
15
char
hostname[HOST_NAME_MAX];
16
if
(gethostname(hostname, HOST_NAME_MAX) != 0)
17
{
18
ROS_FATAL_NAMED(
"utility"
,
"Can't determine hostname"
);
19
throw
std::runtime_error
(
"Can't determine hostname"
);
20
}
21
22
return
std::string
(hostname);
23
}
24
25
}
std::string
exception
rgbd::get_hostname
std::string get_hostname()
Get the hostname of the current machine.
Definition:
utility.cpp:13
utility.h
rgbd
Definition:
client.h:24
std::runtime_error
Generated on Sun Feb 23 2025 04:34:32 for rgbd by
1.8.17