加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
cdrkit-1.1.11-memset.patch 1.39 KB
一键复制 编辑 原始数据 按行查看 历史
hexiaowen 提交于 2019-09-30 10:34 . Package init
diff -up wrk/genisoimage/jte.c.wrk wrk/genisoimage/jte.c
--- wrk/genisoimage/jte.c.wrk 2013-02-22 13:24:47.722196877 +0100
+++ wrk/genisoimage/jte.c 2013-02-25 12:41:45.136653487 +0100
@@ -280,7 +280,7 @@ extern int list_file_in_jigdo(char *file
if (!jtemplate_out)
return 0;
- memset(md5, 0, sizeof(md5));
+ memset(md5, 0, 16);
/* Cheaper to check file size first */
if (size < jte_min_size)
diff -up wrk/genisoimage/md5.c.wrk wrk/genisoimage/md5.c
--- wrk/genisoimage/md5.c.wrk 2013-02-22 13:15:18.210866321 +0100
+++ wrk/genisoimage/md5.c 2013-02-22 13:15:29.979935133 +0100
@@ -183,7 +183,7 @@ mk_MD5Final (unsigned char digest[16], s
putu32(ctx->buf[1], digest + 4);
putu32(ctx->buf[2], digest + 8);
putu32(ctx->buf[3], digest + 12);
- memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */
+ memset(ctx, 0, sizeof(*ctx)); /* In case it's sensitive */
}
/* The four core functions - F1 is optimized somewhat */
diff -up wrk/libedc/edcspeed.c.wrk wrk/libedc/edcspeed.c
--- wrk/libedc/edcspeed.c.wrk 2013-02-22 10:45:33.353219110 +0100
+++ wrk/libedc/edcspeed.c 2013-02-22 10:46:52.497686387 +0100
@@ -35,7 +35,8 @@ static int encspeed()
secs = 10;
end = 75*1000000 * secs;
- memset(sect, 0, sizeof(sect));
+ //faulty and unneccessary, immediately rewritten again
+ //memset(sect, 0, sizeof(sect));
for (i=0; i < 2352; ) {
sect[i++] = 'J';
sect[i++] = 'S';
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化