Bug 746601 - Qt doesn't close orphaned file descriptors after printing
Qt doesn't close orphaned file descriptors after printing
Product: Fedora
Classification: Fedora
Component: qt (Show other bugs)
All Linux
unspecified Severity high
: ---
: ---
Assigned To: Ngo Than
Fedora Extras Quality Assurance
: Patch, Triaged
Depends On:
  Show dependency treegraph
Reported: 2011-10-17 04:20 EDT by zeljko
Modified: 2013-10-04 08:30 EDT (History)
8 users (show)

See Also:
Fixed In Version: qt-4.7.4-6.fc15
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2011-11-10 12:48:19 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
Qt Bug Tracker QTBUG-14724 None None None Never

  None (edit)
Description zeljko 2011-10-17 04:20:46 EDT
Description of problem:
Qt doesn't close file descriptors after printing.
So after passing ulimit -n application cannot open more files anymore,
must be killed.

Related to 
Fix is here (but unmerged for a year)

Version-Release number of selected component (if applicable):


How reproducible:
Just try to print something with some pure qt app (not KDE apps like kwrite)

Steps to Reproduce:
After executing such simple code, you'll see in
your /proc/PROCID/fd/ orphaned symlinks eg.
/proc/PROCID/fd/25->/tmp/cupsXT76YUF (deleted)

so, my macine ulimit -n is 1024, and after printing cca 1000 files, there's
no chance to open another file.

void MainWin::TestMyPrinter() {
  /* just for testing .. */
  QPainter painter;  
  QPrinter printer(QPrinter::PrinterResolution); 
  QPrintDialog *dialog = new QPrintDialog(&printer, this);
     dialog->setWindowTitle(tr("Print Document"));  
  if (dialog->exec() == QDialog::Accepted){
    painter.drawText(200, 200, QString("Hello world"));
    /* does not help */
    /* printer.~QPrinter(); */
Additional info: please apply mentioned patch (http://qt.gitorious.org/qt/qt/merge_requests/982).
Comment 1 Kevin Kofler 2011-10-17 04:38:58 EDT
There hasn't been a qt4 package in Fedora for years, bugs must be filed against qt, not qt4. Reassigning.
Comment 2 zeljko 2011-10-17 04:45:31 EDT
Then remove it from the list of available components.
Comment 3 Kevin Kofler 2011-10-17 05:13:01 EDT
We can't do that. Every package that was ever in Fedora is listed as a Bugzilla component, they're only ever added, never removed.
Comment 4 zeljko 2011-10-17 05:30:36 EDT
Comment 5 zeljko 2011-10-17 10:20:22 EDT
FYI, rebuilded qt-4.7.4 with proposed patch and now it works like a charm, tested with bulk of 15000 files.
Comment 6 Rex Dieter 2011-10-17 10:48:29 EDT
Comment 7 Fedora Update System 2011-10-24 13:54:23 EDT
qt-4.7.4-4.fc14 has been submitted as an update for Fedora 14.
Comment 8 Fedora Update System 2011-10-24 13:54:49 EDT
qt-4.7.4-4.fc15 has been submitted as an update for Fedora 15.
Comment 9 Fedora Update System 2011-10-26 23:58:27 EDT
Package qt-4.7.4-4.fc14:
* should fix your issue,
* was pushed to the Fedora 14 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing qt-4.7.4-4.fc14'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).
Comment 10 Fedora Update System 2011-11-04 10:00:02 EDT
qt-4.7.4-6.fc15 has been submitted as an update for Fedora 15.
Comment 11 Fedora Update System 2011-11-10 12:48:19 EST
qt-4.7.4-4.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 12 zeljko 2011-11-11 02:24:01 EST
hm...I've updated last night machine @home, but only debuginfo package was updated, still got qt-4.7.4-2 (FC14).
Current machine already contains qt from testing, so not in updates at all.
Comment 13 Kevin Kofler 2011-11-11 11:02:38 EST
Your mirror is probably not updated yet. Mirrors have the Fedora 16 release to mirror, it's a lot of stuff, so not all mirrors have managed to pull the latest updates from the master server yet.
Comment 14 Fedora Update System 2011-11-14 17:27:19 EST
qt-4.7.4-6.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 15 Red Hat Bugzilla 2013-10-03 20:21:18 EDT
Removing external tracker bug with the id '14724' as it is not valid for this tracker

Note You need to log in before you can comment on or make changes to this bug.