Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2nd attempt to fix Nemo#594 #5

Merged
merged 2 commits into from Jan 18, 2013
Merged

Conversation

samposa
Copy link
Contributor

@samposa samposa commented Jan 15, 2013

Obtain path for device-info xml from environment.
If $HOME not available find lowest uid from /etc/login.defs and home dir matching that from /etc/passwd.

  • unit test for both cases.

QString DeviceInfo::getDeviceInfoXmlPath()
{
if (m_deviceInfoXmlPath.isEmpty()) {
QString tmpPath = QProcessEnvironment::systemEnvironment().value("HOME");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use QDir::homePath, a much more straightforward way of getting the same thing, and it has the benefit of being cross-platform (not that I imagine this code needs this

rburchell added a commit that referenced this pull request Jan 18, 2013
2nd attempt to fix Nemo#594
@rburchell rburchell merged commit 9b47e35 into nemomobile:master Jan 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants