Mercurial > hg > orthanc
comparison OrthancServer/OrthancRestApi2.cpp @ 218:0200cd330582
fixes
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 29 Nov 2012 13:27:33 +0100 |
parents | 1ac3aacd10a5 |
children | 4eb0c7ce86c9 |
comparison
equal
deleted
inserted
replaced
217:1ac3aacd10a5 | 218:0200cd330582 |
---|---|
254 try | 254 try |
255 { | 255 { |
256 FromDcmtkBridge::ExtractPngImage(png, dicomContent, frame, mode); | 256 FromDcmtkBridge::ExtractPngImage(png, dicomContent, frame, mode); |
257 call.GetOutput().AnswerBuffer(png, "image/png"); | 257 call.GetOutput().AnswerBuffer(png, "image/png"); |
258 } | 258 } |
259 catch (OrthancException&) | 259 catch (OrthancException& e) |
260 { | 260 { |
261 std::string root = ""; | 261 if (e.GetErrorCode() == ErrorCode_NotImplemented) |
262 for (size_t i = 1; i < call.GetFullUri().size(); i++) | |
263 { | 262 { |
264 root += "../"; | 263 std::string root = ""; |
264 for (size_t i = 1; i < call.GetFullUri().size(); i++) | |
265 { | |
266 root += "../"; | |
267 } | |
268 | |
269 call.GetOutput().Redirect(root + "app/images/unsupported.png"); | |
265 } | 270 } |
266 | |
267 call.GetOutput().Redirect(root + "app/images/unsupported.png"); | |
268 } | 271 } |
269 } | 272 } |
270 } | 273 } |
271 | 274 |
272 | 275 |