File permission QFile::WriteOther on Win Dos
If I copy a resource file to a tmp cache dir... so...
MoveAndCopy(QString::fromUtf8(":/images/images/master.sql"),STATIC_TMP_SQL_DUMP);
after this file is readonly to user....
How i set write and remove from application? and edit from user?
Code:
{
if (db->is_file(destfile)) {
db->qt_unlink(destfile);
}
if (!Image.copy(destfile)) {
/*QMessageBox::warning( this,tr( "File Error!" ) , tr("Unable to copy a file to.. %1").arg( destfile ));*/
return false;
} else {
Image2.
setPermissions(QFile::WriteOther);
/* all 0777 */ return true;
}
}
Re: File permission QFile::WriteOther on Win Dos
I dont have Qt here so I can't try it, but I think you need to set all the permissions something like this:
Code:
Image2.
setPermissions(QFile::ReadOwner |
QFile::WriteOwner |
Bojan