// Parse arguments
while (1) {
static const struct option long_options[] = {
- {"help", no_argument, 0, 'h'},
- {"version", no_argument, 0, 'V'},
- {"loglevel", required_argument, 0, 'l'},
- {"input-file", required_argument, 0, 'i'},
- {"input-format", required_argument, 0, 'I'},
- {0, 0, 0, 0}
+ {"help", no_argument, nullptr, 'h'},
+ {"version", no_argument, nullptr, 'V'},
+ {"loglevel", required_argument, nullptr, 'l'},
+ {"input-file", required_argument, nullptr, 'i'},
+ {"input-format", required_argument, nullptr, 'I'},
+ {nullptr, 0, nullptr, 0}
};
const int c = getopt_long(argc, argv,
{
name_widget_ = new QComboBox(parent);
name_widget_->setEditable(true);
- name_widget_->setCompleter(0);
+ name_widget_->setCompleter(nullptr);
for (unsigned int i = 0; i < countof(ChannelNames); i++)
name_widget_->insertItem(i, ChannelNames[i]);
sigemptyset(&sig_action.sa_mask);
sig_action.sa_flags = SA_RESTART;
- if (sigaction(SIGINT, &sig_action, 0) != 0 ||
- sigaction(SIGTERM, &sig_action, 0) != 0) {
+ if (sigaction(SIGINT, &sig_action, nullptr) != 0 ||
+ sigaction(SIGTERM, &sig_action, nullptr) != 0) {
close(sockets_[0]);
close(sockets_[1]);
return false;
}
SignalHandler::SignalHandler(QObject* parent) : QObject(parent),
- socket_notifier_(0)
+ socket_notifier_(nullptr)
{
socket_notifier_ = new QSocketNotifier(sockets_[1],
QSocketNotifier::Read, this);