monitor names incorrect in dual monitor setup
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Xfce4 Settings |
Fix Released
|
Medium
|
|||
xfce4-settings (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
The 'display settings' mis-labels the two monitors connected to my computer. I have an ASUS monitor and a ViewSonic monitor. The ASUS monitor is labeled ViewSonic, and the ViewSonic is labeled HDMI1. This mis-labeling is the only apparent error. 'Display settings' otherwise correctly recognizes the monitor specifications. The monitors are correctly displayed in relationship to one another.
ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: xfce4-settings 4.11.2-1ubuntu1
ProcVersionSign
Uname: Linux 3.13.0-19-generic x86_64
ApportVersion: 2.13.3-0ubuntu1
Architecture: amd64
CasperVersion: 1.339
CurrentDesktop: XFCE
Date: Mon Mar 31 15:05:57 2014
ExecutablePath: /usr/bin/
LiveMediaBuild: Xubuntu 14.04 LTS "Trusty Tahr" - Beta amd64 (20140326)
ProcEnviron:
PATH=(custom, no user)
XDG_RUNTIME_
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: xfce4-settings
UpgradeStatus: No upgrade log present (probably fresh install)
Changed in xfce4-settings: | |
importance: | Unknown → Medium |
status: | Unknown → Confirmed |
Changed in xfce4-settings: | |
status: | Confirmed → Fix Released |
Changed in xfce4-settings (Ubuntu): | |
status: | Confirmed → Fix Released |
in xfce_randr_populate is this piece of code:
/* prepare the temporary cache */
outputs = g_ptr_array_new ();
/* walk the outputs */ priv->resources ->noutput; ++n) priv->resources ,
randr- >priv-> resources- >outputs[ n]);
for (n = 0; n < randr->
{
/* get the output info */
output_info = XRRGetOutputInfo (xdisplay, randr->
/* forget about disconnected outputs */ info->connectio n != RR_Connected)
XRRFreeOut putInfo (output_info);
continue;
if (output_
{
}
/* cache it */
g_ptr_ array_add (outputs, output_info);
}
/* migrate the temporary cache */ >priv-> output_ info = (XRROutputInfo **) g_ptr_array_free (outputs, FALSE);
randr->noutput = outputs->len;
randr-
This gets the info for each output, and if the output is connected it store the info.
Later on is this:
/* walk the connected outputs */
for (m = 0; m < randr->noutput; ++m)
{
...
randr- >friendly_ name[m] = xfce_randr_ friendly_ name (randr, m);
/* fill in the name used by the UI */
...
}
Inside friendly name it eventually does this:
edid_data = xfce_randr_ read_edid_ data (xdisplay, randr-> priv->resources ->outputs[ output] );
Here, output = m.
This is invalid because m only counts connected outputs, but is being used as an offset into randr-> priv->resources ->outputs, which includes unconnected outputs. As a result, all the connected monitor names are wrong if you have unconnected displays.
Commenting this piece of code fixes the problem:
/* forget about disconnected outputs */ info->connectio n != RR_Connected)
XRRFreeOut putInfo (output_info);
continue;
if (output_
{
}
However, this causes all unconnected outputs to be listed in the display settings (although they are "greyed" indicating they are not connected).