Opened 17 years ago
Closed 16 years ago
#2113 closed defect (fixed)
Bugfix for procps
Reported by: | Arthur Demchenkov | Owned by: | |
---|---|---|---|
Priority: | high | Milestone: | 6.4 |
Component: | Book | Version: | SVN |
Severity: | normal | Keywords: | |
Cc: |
Description
Hello everyone.
Here is the patch that fixes two bugs in watch program from procps-3.2.7: 1) watch -n doesn't handle large integers properly 2) watch ignores multibyte characters (was pointed in locale related issues chapter of BLFS book earlier)
It's adapted from Fedora Core procps source rpm to LFS.
Attachments (3)
Change History (15)
by , 17 years ago
Attachment: | procps-3.2.7-watch_fix.patch added |
---|
follow-up: 2 comment:1 by , 17 years ago
comment:2 by , 17 years ago
You are right. The first patch is some kind of atavism. I removed it.
I'm reattaching the properly patch to make watch to work with unicode.
by , 17 years ago
Attachment: | procps-3.2.7-watch-unicode.patch added |
---|
comment:3 by , 17 years ago
Still, you didn't explain why you dropped the "close fd 0" part. I didn't say that it is bad - I only noted the inaccurate patch description.
As for the unicode patch, it is definitely better than nothing, but I still haven't tested it. From looking at the code, it seems that it mishandles zero-width characters.
comment:4 by , 17 years ago
Hello, Alexander.
As I said before the first patch is compilation of two patches from Fedora Core 6 src.rpm
The first one is called procps-3.1.15-misc.patch (that's about fd0)
The second on is called procps-3.2.7-watch-unicode.patch
But the problem was the second patch needed the first one. So I checked rpm's spec file for occurence of 'watch' and found 2 bugs (the first one was in procps-3.2.6 so my description was incorrect as this bug was fixed in procps-3.2.7):
* Thu Apr 26 2007 Tomas Smetana <tsmetana@redhat.com> 3.2.7-9 - fix #183029 - watch ignores multibyte characters * Thu Jun 1 2006 Karel Zak <kzak@redhat.com> -> 3.2.6-4 <- - fix #191493 - watch -n doesn't handle large integers properly
So after your message I checked that watch -n 12345678901234 <some command> works as expected without the first patch and I removed it. But if you know why watch needs it you are free to apply it. Looking at its name it comes from ancient version of procps-3.1.15.
I'm attaching original source converted to cpio.
by , 17 years ago
Attachment: | procps-3.2.7-12.fc6.tar.bz2 added |
---|
Replaced with tar.bz2 without procps-3.2.7.tar.gz because of limited size of attachments
comment:5 by , 17 years ago
I can't reproduce the 'watch -n' bug at https://bugzilla.redhat.com/show_bug.cgi?id=191493.
Anyone else?
follow-up: 7 comment:6 by , 17 years ago
The "watch -n" bug was relevant for versions 3.2.6 and below. procps 3.2.7 silently caps the interval to 4294 seconds. So we only have the unicode-related bug.
comment:7 by , 17 years ago
Replying to alexander@linuxfromscratch.org:
The "watch -n" bug was relevant for versions 3.2.6 and below. procps 3.2.7 silently caps the interval to 4294 seconds. So we only have the unicode-related bug.
Yes, unicode-related bug is fixed with procps-3.2.7-watch-unicode.patch. Do you have any contraindication on applying it?
comment:9 by , 16 years ago
Milestone: | 7.0 → 6.4 |
---|
comment:10 by , 16 years ago
Priority: | normal → high |
---|
This is marked for the next release, but a consensus has not even been reached on this issue. We need to revisit this as a 6.4 ticket.
comment:11 by , 16 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:12 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Added the watch_unicode patch to the Procps instructions in r8636.
As far as I can see: