add u7/cnorm/civis to windows

This commit is contained in:
nick black 2021-08-04 02:36:10 -04:00 committed by nick black
parent f64258f468
commit a0007a9a3c
2 changed files with 4 additions and 3 deletions

View File

@ -605,7 +605,7 @@ file(GLOB MANSOURCE3 CONFIGURE_DEPENDS doc/man/man3/*.md)
# all further binaries require multimedia support
if(${USE_MULTIMEDIA} STREQUAL "none" OR WIN32)
list(FILTER MANSOURCE1 EXCLUDE REGEX "ncls.1.md")
list(FILTER MANSOURCE1 EXCLUDE REGEX "ncplayer.1.md")
#list(FILTER MANSOURCE1 EXCLUDE REGEX "ncplayer.1.md")
else()
############################################################################
# ncls

View File

@ -307,7 +307,7 @@ getlocalhostname(fetched_info* fi){
}
return -1;
}
#else
#else // windows
static int
getusername(fetched_info* fi){
DWORD unlen = UNLEN + 1;
@ -326,7 +326,8 @@ getusername(fetched_info* fi){
static int
getlocalhostname(fetched_info* fi){
char lp[MAX_COMPUTERNAME_LENGTH + 1];
if(GetComputerNameA(lp, sizeof(lp))){
size_t s = sizeof(lp);
if(GetComputerNameA(lp, &s)){
if( (fi->hostname = strdup(lp)) ){
return 0;
}