Browse Source

Bugfix: hashbuster: Use maybe_strdup where there might not be a string

Luke Dashjr 12 years ago
parent
commit
8bd66f2428
1 changed files with 3 additions and 3 deletions
  1. 3 3
      driver-hashbuster.c

+ 3 - 3
driver-hashbuster.c

@@ -189,9 +189,9 @@ bool hashbuster_foundlowl(struct lowlevel_device_info * const info, __maybe_unus
 		.threads = 1,
 		.threads = 1,
 		.procs = chip_n,
 		.procs = chip_n,
 		.device_path = strdup(info->path),
 		.device_path = strdup(info->path),
-		.dev_manufacturer = strdup(info->manufacturer),
-		.dev_product = strdup(product),
-		.dev_serial = strdup(serial),
+		.dev_manufacturer = maybe_strdup(info->manufacturer),
+		.dev_product = maybe_strdup(product),
+		.dev_serial = maybe_strdup(serial),
 		.deven = DEV_ENABLED,
 		.deven = DEV_ENABLED,
 	};
 	};