1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

illumos: fix build errors

This commit is contained in:
Zhiwen Zheng 2019-11-04 18:09:34 +08:00 committed by Andy Green
parent 37898cc3f3
commit 3299c54130
3 changed files with 5 additions and 2 deletions

View file

@ -185,6 +185,9 @@ lws_json_dump_context(const struct lws_context *context, char *buf, int len,
(long)d);
#ifdef LWS_HAVE_GETLOADAVG
#if defined(__sun)
#include <sys/loadavg.h>
#endif
{
double d[3];
int m;

View file

@ -106,7 +106,7 @@ lws_dir(const char *dirpath, void *user, lws_dir_callback_function cb)
* files are LDOT_UNKNOWN
*/
#if defined(__illumos__)
#if defined(__sun)
struct stat s;
stat(namelist[i]->d_name, &s);
switch (s.st_mode) {

View file

@ -252,7 +252,7 @@ int main(int argc, char **argv)
signal(SIGHUP, reload_handler);
signal(SIGINT, reload_handler);
fprintf(stderr, "Root process is %u\n", getpid());
fprintf(stderr, "Root process is %u\n", (unsigned int)getpid());
while (1) {
if (do_reload) {