summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xresponsememblk.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/responsememblk.c b/responsememblk.c
index 273890a..5fe4118 100755
--- a/responsememblk.c
+++ b/responsememblk.c
@@ -2211,9 +2211,11 @@ int cResponseMemBlk::sendRecordingsXml(struct stat *statbuf) {
}
if (mRequest->getQueryAttributeValue(&avps, "guid", guid) == OKAY){
+ guid = cUrlEncode::doUrlSaveDecode(guid);
*(mLog->log())<< DEBUGPREFIX
<< " Found a guid Parameter: " << guid
<< endl;
+
single_item = true;
}
@@ -2312,8 +2314,12 @@ int cResponseMemBlk::sendRecordingsXml(struct stat *statbuf) {
cRecording *recording = NULL;
if (single_item) {
recording = Recordings.GetByName(guid.c_str());
- if (recording == NULL)
+ if (recording == NULL) {
*(mLog->log())<< DEBUGPREFIX << " WARNING in sendRecordingsXml: recording " << guid << " not found" << endl;
+ sendError(400, "Bad Request", NULL, "007 Failed to find the recording.");
+ return OKAY;
+ }
+
}
else {
recording = Recordings.First();