注意!hls mp4录制的customized path字段改成录制根目录 相当于配置文件中hls mp4录制根目录相关设置

This commit is contained in:
xiongziliang
2020-10-01 14:55:34 +08:00
parent 8b7c792e44
commit cd27e5a9f9
2 changed files with 5 additions and 12 deletions

View File

@@ -31,7 +31,7 @@ string Recorder::getRecordPath(Recorder::type type, const string &vhost, const s
}
//Here we use the customized file path.
if (!customized_path.empty()) {
m3u8FilePath = customized_path + "/hls.m3u8";
return File::absolutePath(m3u8FilePath, customized_path);
}
return File::absolutePath(m3u8FilePath, hlsPath);
}
@@ -46,15 +46,8 @@ string Recorder::getRecordPath(Recorder::type type, const string &vhost, const s
}
//Here we use the customized file path.
if (!customized_path.empty()) {
/*开始删除*/
// mp4FilePath = customized_path + "/";
/*删除结束*/
/*开始添加*/
//@子悦,你上次说这里为了安全不能跳出目录,但实际操作过程中因为存储挂载位置不由流媒体决定,为了方便保存到挂载存储上,我这边做成可以跳出自已目录,你看是否合适,或者有其他办法可以处理这事
return customized_path + "/"+mp4FilePath;
/*开始添加*/
return File::absolutePath(mp4FilePath, customized_path);
}
return File::absolutePath(mp4FilePath, recordPath);
}
default: