From c1fe6dc3f5cbf7351651be2b698e295d22ecdd6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Fri, 12 Apr 2024 22:51:42 +0900 Subject: [PATCH] fix(compile): remove c99 restriction --- CMakeLists.txt | 4 ---- cmoe.c | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e87d805..2dba913 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -5,10 +5,6 @@ SET(CMAKE_BUILD_TYPE "Release") include_directories("/usr/local/include") link_directories("/usr/local/lib") -#在编译选项中加入c99支持 -add_compile_options(-std=c99) -message(STATUS "optional:-std=c99") - add_executable(cmoe cmoe.c) add_executable(cmoeditor editor.c) diff --git a/cmoe.c b/cmoe.c index 0914769..d56045d 100644 --- a/cmoe.c +++ b/cmoe.c @@ -199,7 +199,7 @@ int main(int argc, char **argv) { theme = get_arg(theme + 6); } char* reg = strstr(QS, "reg="); - int fd; + int fd; if (!reg) { if ((fd=create_or_open(datfile)) < 0) { http_error(HTTP500, "Open File Error.");