Bug 251076 - Application locks up
Summary: Application locks up
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: system-config-users
Version: 7
Hardware: i386
OS: Linux
low
low
Target Milestone: ---
Assignee: Nils Philippsen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-08-06 22:08 UTC by ray hammond
Modified: 2007-11-30 22:12 UTC (History)
1 user (show)

Fixed In Version: 1.2.64-1.fc7
Clone Of:
Environment:
Last Closed: 2007-09-18 03:20:32 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description ray hammond 2007-08-06 22:08:51 UTC
Description of problem:
Application locks up after creating test user.

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

How reproducible:
Everytime

Steps to Reproduce:
1.Start Users and Groups utility from the Gnome Settings->Administration menu
2.When prompted input the root password
3.Press the Add user button
4.Enter a user name of TEST
5.Enter a password of 123456
6.Enter the password again in the confirmation box
7.Uncheck "Create home directory" checkbox
8.Uncheck "Create a private group for the user
9. Press OK
10. Answer Yes to the weak password warning

Actual results:
The new user dialog closes and main window goes grey, the pointer changes to 
the wait cursor.  From this point on the main window remains grey and the 
cursor remains as the wait cursor.

Expected results:

The main windows should display the new user.

Additional info:

This is a virgin install of Fedora.

Comment 1 Nils Philippsen 2007-08-15 09:02:39 UTC
Mirek, I get this on the console (with the current Hg upstream code):

/home/nils/devel/hg/hosted/system-config-users/src/mainWindow.py:394:
RuntimeWarning: tp_compare didn't return -1 or -2 for exception
  groupEnt = self.gid_dict[long (gidNumber)]
Traceback (most recent call last):
  File "/home/nils/devel/hg/hosted/system-config-users/src/userWindow.py", line
402, in on_userWin_ok_button_clicked
    self.parent.refresh_users_and_groups([userName, 'users'])
  File "/home/nils/devel/hg/hosted/system-config-users/src/mainWindow.py", line
394, in refresh_users_and_groups
    groupEnt = self.gid_dict[long (gidNumber)]
RuntimeError: Error creating `': No such file or directory

This looks like a libuser runtime error but I can't imagine why it happens at
that point. Would you please take a look at this?

I've got libuser-0.56.2-1. You can pull the current repository from
hg.fedoraproject.org.

Comment 2 Miloslav Trmač 2007-08-15 21:09:29 UTC
The Python traceback has incorrect location information.

Without trying this in the debugger, I think this is caused by:
        if self.homeDirCheck.get_active():
            userEnt.set(libuser.HOMEDIRECTORY, [homeDir])
        else:
            userEnt.set(libuser.HOMEDIRECTORY, [""])
... so userEnt[HOMEDIRECTORY] is "".  Later:
        if self.homeDirCheck.get_active():
            #Create a home directory for the user
            self.parent.ADMIN.addUser(userEnt)
        else:
            #Do not create a home directory for the user
            self.parent.ADMIN.addUser(userEnt)
            homeDir = ""
Note:
1) the addUser call is the same in both cases, attempting to create the
   directory "", which is an invalid file name in Unix.
2) the homeDir assignment is not used anywhere

I think userent[HOMEDIRECTORY] should always be set to homeDir, and the second
case of addUser should use mkhomedir = False.


Comment 3 Nils Philippsen 2007-08-16 19:45:16 UTC
I've fixed this in system-config-users-1.2.63 which should updates-testing
shortly. Please test this version. Thanks!

Comment 4 Fedora Update System 2007-08-17 16:12:47 UTC
system-config-users-1.2.64-1.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.

Comment 5 Fedora Update System 2007-09-18 03:20:25 UTC
system-config-users-1.2.64-1.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.


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