在这样的行上不断收到警告
qDebug("An error occured while trying to create folder " + workdir.toAscii());
workdir 是 QString()
warning: format not a string literal and no format arguments
最佳答案
大概应该是:
qDebug("An error occured while trying to create folder %s", workdir.constData());
自 qDebug
将 const char*
作为第一个参数。
关于c++ - Qt - 获取 "warning: format not a string literal and no format arguments",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4280697/