1 Star 0 Fork 2

brucezhang/cvs

forked from OpenCloudOS Stream/cvs 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
cvs-1.11.23-c99.patch 1.45 KB
一键复制 编辑 原始数据 按行查看 历史
fanjunkong 提交于 2024-08-01 20:22 +08:00 . update
Downstream-only patch. CVS hasn't had a release since 2008.
diff --git a/lib/getdate.c b/lib/getdate.c
index 5180358c85f8a050..18a6ce0416aa188b 100644
--- a/lib/getdate.c
+++ b/lib/getdate.c
@@ -1019,7 +1019,7 @@ main(ac, av)
(void)printf("Enter date, or blank line to exit.\n\t> ");
(void)fflush(stdout);
- while (gets(buff) && buff[0]) {
+ while (fgets(buff, sizeof(buff) - 1, stdin) && buff[0]) {
d = get_date(buff, (struct timeb *)NULL);
if (d == -1)
(void)printf("Bad format - couldn't convert.\n");
diff --git a/lib/getdate.y b/lib/getdate.y
index 0e128d74ef609818..007318cd0aef2623 100644
--- a/lib/getdate.y
+++ b/lib/getdate.y
@@ -1015,7 +1015,7 @@ main(ac, av)
(void)printf("Enter date, or blank line to exit.\n\t> ");
(void)fflush(stdout);
- while (gets(buff) && buff[0]) {
+ while (fgets(buff, sizeof(buff) - 1, stdin) && buff[0]) {
d = get_date(buff, (struct timeb *)NULL);
if (d == -1)
(void)printf("Bad format - couldn't convert.\n");
diff --git a/src/cvs.h b/src/cvs.h
index a7f4b2f6bd6c67fb..cd6ffc9bbd7859aa 100644
--- a/src/cvs.h
+++ b/src/cvs.h
@@ -486,6 +486,7 @@ extern int parse_config PROTO ((char *));
typedef RETSIGTYPE (*SIGCLEANUPPROC) PROTO(());
int SIG_register PROTO((int sig, SIGCLEANUPPROC sigcleanup));
+int SIG_deregister PROTO((int sig, SIGCLEANUPPROC sigcleanup));
int isdir PROTO((const char *file));
int isfile PROTO((const char *file));
int islink PROTO((const char *file));
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/bbrucezhang/cvs.git
git@gitee.com:bbrucezhang/cvs.git
bbrucezhang
cvs
cvs
master

搜索帮助