summaryrefslogtreecommitdiff
path: root/src/qcam/assets/feathericons/truck.svg
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-03-01 17:56:59 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-03-06 18:10:45 +0200
commit44ff5a18e42ad26a1621edf00f309c86304f13ac (patch)
treecd836cfc9980f2f211ba7aca78751727ac963c0b /src/qcam/assets/feathericons/truck.svg
parent7f2da874cdacf2870c7a55cd1bdf34a01b01787d (diff)
libcamera: control_serializer: Use explicit ControlTypeNone case
Replace the default case with an explicit ControlTypeNone case in ControlSerializer::load() to catch omissions when adding new control types. A return statement needs to be added to the end of the function to avoid gcc incorrectly reporting that some exit paths don't contain a return statement. The compiler will still warn that not all cases are handled when adding a new control type. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src/qcam/assets/feathericons/truck.svg')
0 files changed, 0 insertions, 0 deletions
c_unixsocket.h" #include "log.h" #include "process.h" namespace libcamera { LOG_DECLARE_CATEGORY(IPAProxy) class IPAProxyLinux : public IPAProxy { public: IPAProxyLinux(IPAModule *ipam); ~IPAProxyLinux(); int init() override { return 0; } void configure(const std::map<unsigned int, IPAStream> &streamConfig, const std::map<unsigned int, const ControlInfoMap &> &entityControls) override {} void mapBuffers(const std::vector<IPABuffer> &buffers) override {} void unmapBuffers(const std::vector<unsigned int> &ids) override {} void processEvent(const IPAOperationData &event) override {} private: void readyRead(IPCUnixSocket *ipc); Process *proc_; IPCUnixSocket *socket_; }; IPAProxyLinux::IPAProxyLinux(IPAModule *ipam) : proc_(nullptr), socket_(nullptr) { LOG(IPAProxy, Debug) << "initializing dummy proxy: loading IPA from " << ipam->path(); std::vector<int> fds; std::vector<std::string> args; args.push_back(ipam->path()); const std::string path = resolvePath("ipa_proxy_linux"); if (path.empty()) { LOG(IPAProxy, Error) << "Failed to get proxy worker path"; return; } socket_ = new IPCUnixSocket(); int fd = socket_->create(); if (fd < 0) { LOG(IPAProxy, Error) << "Failed to create socket"; return; } socket_->readyRead.connect(this, &IPAProxyLinux::readyRead); args.push_back(std::to_string(fd)); fds.push_back(fd); proc_ = new Process(); int ret = proc_->start(path, args, fds); if (ret) { LOG(IPAProxy, Error) << "Failed to start proxy worker process"; return; } valid_ = true; } IPAProxyLinux::~IPAProxyLinux() { delete proc_; delete socket_; } void IPAProxyLinux::readyRead(IPCUnixSocket *ipc) { } REGISTER_IPA_PROXY(IPAProxyLinux) } /* namespace libcamera */