Bug 189493

Summary: [PATCH] off by one in pbs_sched
Product: [Fedora] Fedora Reporter: Fabrice Bellet <fabrice>
Component: torqueAssignee: Garrick Staples <garrick>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 4CC: extras-qa, fabrice
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 2.1.0p0-0.10.200604211036cvs Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-04-21 17:17:39 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Fabrice Bellet 2006-04-20 14:58:49 UTC
this patch fixes a trivial problem in pbs_sched when counting the number of
chars written to its lock file. This error prevents this daemon from starting up.


--- torque-2.1.0p0-snap.200604171430/src/scheduler.cc/pbs_sched.c.orig 
2006-04-06 23:56:37.000000000 +0200
+++ torque-2.1.0p0-snap.200604171430/src/scheduler.cc/pbs_sched.c      
2006-04-20 16:52:38.000000000 +0200
@@ -992,7 +992,7 @@

         (void)sprintf(log_buffer, "%ld\n", (long)pid);

-        if (write(lockfds, log_buffer, strlen(log_buffer)+1) != strlen(log_buffer))
+        if (write(lockfds, log_buffer, strlen(log_buffer)+1) !=
strlen(log_buffer)+1)
           {
           perror("writing to lockfile");

Comment 1 Garrick Staples 2006-04-20 16:49:32 UTC
That's impressive.  TORQUE has been in FE for 1 day!

I'll get this upstream and probably have a new package tomorrow.

Thanks for the patch!