diff options
author | Clayton <nrootconauto@gmail.com> | 2023-02-28 15:04:52 -0500 |
---|---|---|
committer | Clayton <nrootconauto@gmail.com> | 2023-02-28 15:04:52 -0500 |
commit | 95e3143eaf9455feeff9e60a3a584ce15b8cd118 (patch) | |
tree | febab6739415a5638f684d17f96750b5cff8decc | |
parent | 2bcbe3f662ffc2769af7baa53f6f8f31ac5d7ca2 (diff) |
Fixed bug,set timeout
I fixed a bug,"restoring" a created file to original state deletes it. Added timeout
-rw-r--r-- | T/Server/backup.HC | 2 | ||||
-rw-r--r-- | T/Server/http.HC | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/T/Server/backup.HC b/T/Server/backup.HC index 47fdde8..5092fde 100644 --- a/T/Server/backup.HC +++ b/T/Server/backup.HC @@ -194,7 +194,7 @@ U0 DeleteUserEdits(U8 *user) { Del(sorted[i]->full_name); sorted[i]->user_data=TRUE; } else if(StrOcc(flags,'c')) //We will mark the creation for deletion,but will do it below - sorted[i]->user_data=TRUE; + sorted[i]->user_data=FALSE; else sorted[i]->user_data=FALSE; Free(ftxt); diff --git a/T/Server/http.HC b/T/Server/http.HC index cae3805..1099a41 100644 --- a/T/Server/http.HC +++ b/T/Server/http.HC @@ -604,6 +604,7 @@ found: U0 ListenCallback(CDyadStream *s,CServer *srv) { CUniqueToken *ut=MAlloc(sizeof(CUniqueToken)); ut->srv=srv; + DyadSetTimeout(s,1); DyadSetReadCallback(s,&SReadLine,ut); DyadSetOnCloseCallback(s,&CloseCallback,ut); } |