Browse Source

n0 need to use the char '0' for memsetting an int array [[=[=[==[=[

Wazakindjes 2 months ago
parent
commit
85df8622b1
2 changed files with 2 additions and 2 deletions
  1. 1 1
      src/cputemps.c
  2. 1 1
      src/fans.c

+ 1 - 1
src/cputemps.c

@@ -15,7 +15,7 @@ unsigned short int read_data(void) {
 	char rawdata[32];
 
 	ret = 0;
-	memset(&demcores, '\0', sizeof(demcores));
+	memset(&demcores, 0, sizeof(demcores));
 	for(i = conf_cputemps_firstcore, j = 0; i <= conf_cputemps_lastcore; i++) {
 		if(check_skippem(conf_cputemps_skipcores, conf_cputemps_firstcore, conf_cputemps_lastcore, i))
 			continue;

+ 1 - 1
src/fans.c

@@ -15,7 +15,7 @@ unsigned short int read_data(void) {
 	char rawdata[32];
 
 	ret = 0;
-	memset(&demfans, '\0', sizeof(demfans));
+	memset(&demfans, 0, sizeof(demfans));
 	for(i = conf_fans_firstfan, j = 0; i <= conf_fans_lastfan; i++) {
 		if(check_skippem(conf_fans_skipfans, conf_fans_firstfan, conf_fans_lastfan, i))
 			continue;