Skip to content

Commit 7c9f20b

Browse files
authored
Merge pull request #45 from JamesHeinrich/master
Checksum errors from uninitialized variable
2 parents d06464f + ae0e875 commit 7c9f20b

File tree

4 files changed

+5
-6
lines changed

4 files changed

+5
-6
lines changed

README.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
** Preface for mfakto 0.16.0-beta.4 **
1+
** Preface for mfakto 0.16.0-beta.5 **
22

33
This is a developmental version of mfakto. It has been verified to produce
44
correct results. However, there may be bugs and incomplete features, and

src/mfakto.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -830,7 +830,7 @@ void set_gpu_type()
830830
printf("Warning: Unknown GPU name, assuming a GCN (Graphics Core Next) device. Please\n"
831831
" post the name to the GIMPS forum or GitHub to have it added to mfakto.\n\n"
832832
" Device name: %s (%s)\n"
833-
" mfakto thread: http://mersenneforum.org/showthread.php?t=15646\n"
833+
" mfakto thread: https://www.mersenneforum.org/node/11037\n"
834834
" GitHub: https://github.com/primesearch/mfakto/issues\n\n"
835835
" You can also set GPUType in %s to avoid this message.\n",
836836
deviceinfo.d_name, deviceinfo.v_name, mystuff.inifile);

src/output.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -520,7 +520,6 @@ void print_result_line(mystuff_t *mystuff, int factorsfound)
520520
char factors_list[500];
521521
char factors_quote_list[500];
522522
char osjson[200];
523-
char details[50];
524523
char txtstring[200];
525524
char json_checksum_string[750];
526525
char timestamp[50];
@@ -609,8 +608,8 @@ void print_result_line(mystuff_t *mystuff, int factorsfound)
609608
mystuff->exponent, mystuff->bit_min, mystuff->bit_max_stage,
610609
MFAKTO_VERSION, mystuff->stats.kernelname);
611610
}
612-
snprintf(json_checksum_string, sizeof(json_checksum_string), "%u;TF;%s;;%d;%d;%u;;;mfakto;%s;%s;%s;%s;%s;%s", mystuff->exponent,
613-
factors_list, mystuff->bit_min, mystuff->bit_max_stage, !partialresult, SHORT_MFAKTO_VERSION, mystuff->stats.kernelname, details,
611+
snprintf(json_checksum_string, sizeof(json_checksum_string), "%u;TF;%s;;%d;%d;%u;;;mfakto;%s;%s;;%s;%s;%s", mystuff->exponent,
612+
factors_list, mystuff->bit_min, mystuff->bit_max_stage, !partialresult, SHORT_MFAKTO_VERSION, mystuff->stats.kernelname,
614613
getOS(), getArchitecture(), timestamp);
615614
json_checksum = crc32_checksum(json_checksum_string, strlen(json_checksum_string));
616615
sprintf(jsonstring, "{\"exponent\":%u, \"worktype\":\"TF\", \"status\":\"%s\", \"bitlo\":%d, \"bithi\":%d, \"rangecomplete\":%s%s, \"program\":{\"name\":\"mfakto\", \"version\":\"%s\", \"kernel\":\"%s\"}, \"timestamp\":\"%s\"%s%s%s%s, \"checksum\":{\"version\":%u, \"checksum\":\"%08X\"}}",

src/params.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ than an equal SIEVE_SIZE_LIMIT #define.
105105
Please discuss with the community before making changes to version numbers!
106106
*/
107107

108-
#define SHORT_MFAKTO_VERSION "0.16.0-beta.4"
108+
#define SHORT_MFAKTO_VERSION "0.16.0-beta.5"
109109

110110
#ifdef _MSC_VER
111111
#define MFAKTO_VERSION "mfakto " SHORT_MFAKTO_VERSION "-Win"

0 commit comments

Comments
 (0)