aboutsummaryrefslogtreecommitdiff
path: root/captain/external.f90
diff options
context:
space:
mode:
authorJeffrey Armstrong <jeff@approximatrix.com>2021-08-17 08:26:20 -0400
committerJeffrey Armstrong <jeff@approximatrix.com>2021-08-17 08:26:20 -0400
commitd1e500b626de0c906273f3cf4e21479779f48aef (patch)
treeca1d44ce13941f80016b6e29327f903ce32d77e6 /captain/external.f90
parentcd4a5891b8e2a019fdfda7512d6490e075628292 (diff)
downloadlevitating-d1e500b626de0c906273f3cf4e21479779f48aef.tar.gz
levitating-d1e500b626de0c906273f3cf4e21479779f48aef.zip
Titan writing routine server-side is now a function returning success in case file can't be written.
Diffstat (limited to 'captain/external.f90')
-rw-r--r--captain/external.f9014
1 files changed, 10 insertions, 4 deletions
diff --git a/captain/external.f90 b/captain/external.f90
index f5ba409..61184f1 100644
--- a/captain/external.f90
+++ b/captain/external.f90
@@ -718,11 +718,17 @@ contains
! Write the file
call write_log("Storing titan file to "//trim(fullpath), LOG_DEBUG)
- call req%write_to(fullpath)
+ if(req%write_to(fullpath)) then
- resp%code = GEMINI_CODE_SUCCESS
- call resp%set_body_contents(RESPONSE_JSON_OKAY)
- resp%body_mimetype = "text/plain"
+ resp%code = GEMINI_CODE_SUCCESS
+ call resp%set_body_contents(RESPONSE_JSON_OKAY)
+ resp%body_mimetype = "text/plain"
+
+ else
+
+ resp%code = GEMINI_CODE_TEMPFAIL
+
+ end if
else