ALT Linux repositórios
Group :: Sistema/Servidores
RPM: nut
Main Changelog Spec Patches Sources Download Gear Bugs e FR Repocop
Patch: nut-2.0.2-alt-drivers.patch
Download
Download
--- nut-2.0.2/drivers/main.c 2005-05-04 13:36:36 +0400
+++ nut-2.0.1/drivers/main.c 2004-08-12 13:45:18 +0400
@@ -540,6 +540,18 @@
upsdebugx(1, "debug level is '%d'", nut_debug_level);
+ upsdrv_initups();
+
+ /* now see if things are very wrong out there */
+ if (broken_driver) {
+ printf("Fatal error: broken driver. It probably needs to be converted.\n");
+ printf("Search for 'broken_driver = 1' in the source for more details.\n");
+ exit(EXIT_FAILURE);
+ }
+
+ if (do_forceshutdown)
+ forceshutdown();
+
if ((new_uid = get_user_pwent(user)) == NULL)
fatal("getpwnam(%s)", user);
@@ -556,18 +568,6 @@
/* clear out callback handler data */
memset(&upsh, '\0', sizeof(upsh));
- upsdrv_initups();
-
- /* now see if things are very wrong out there */
- if (broken_driver) {
- printf("Fatal error: broken driver. It probably needs to be converted.\n");
- printf("Search for 'broken_driver = 1' in the source for more details.\n");
- exit(EXIT_FAILURE);
- }
-
- if (do_forceshutdown)
- forceshutdown();
-
/* get the base data established before allowing connections */
upsdrv_initinfo();
upsdrv_updateinfo();