Explorar o código

core: explicitly cast void* to char* in shm_char_dup()

- fix gcc 9.2 warning
- GH #2191
James Aimonetti %!s(int64=5) %!d(string=hai) anos
pai
achega
e656ed7400
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/core/ut.h

+ 1 - 1
src/core/ut.h

@@ -808,7 +808,7 @@ static inline char* shm_char_dup(const char *src)
 	}
 
 	len = strlen(src) + 1;
-	rval = shm_malloc(len);
+	rval = (char*)shm_malloc(len);
 	if (!rval) {
 		SHM_MEM_ERROR;
 		return NULL;