FreeBSD Bugzilla – Attachment 230075 Details for
Bug 260381
regression: moused(8), sysmouse(4) or psm(4) delays button release events by about 900ms
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
Source of the test command used to produce the traces in the bug report
mouseinspect.c (text/plain), 973 bytes, created by
Bertrand Petit
on 2021-12-13 09:16:01 UTC
(
hide
)
Description:
Source of the test command used to produce the traces in the bug report
Filename:
MIME Type:
Creator:
Bertrand Petit
Created:
2021-12-13 09:16:01 UTC
Size:
973 bytes
patch
obsolete
>#include <errno.h> >#include <string.h> >#include <stdio.h> >#include <fcntl.h> >#include <unistd.h> >#include <sys/time.h> > >int main(int argc, char *argv[]) >{ > if(argc!=2) > { > printf("usage: %s <mousedev>\n", argv[0]); > return 1; > } > > int MouseFd=open(argv[1], O_RDONLY); > if(MouseFd<0) > { > printf("can't open %s (%s)\n", argv[0], strerror(errno)); > return 1; > } > > char ReadBuf[8]; > ssize_t ReadSize; > > while((ReadSize=read(MouseFd, ReadBuf, 8))==8) > { > struct timeval Time; > if(gettimeofday(&Time, NULL)) > { > printf("can't get the time of day (%s)\n", strerror(errno)); > return 1; > } > >#define BTNSTATECHAR(a) ((a)?'u':'d') > printf("%ld.%06ld Buttons: %c %c %c\n", > Time.tv_sec, Time.tv_usec, > BTNSTATECHAR(ReadBuf[0]&(1<<2)), > BTNSTATECHAR(ReadBuf[0]&(1<<1)), > BTNSTATECHAR(ReadBuf[0]&(1<<0))); > fflush(stdout); > } > printf("read error on %s (%s\n", argv[1], strerror(errno)); > return 1; >} > >/* > * Local Variables: > * tab-width: 4 > * End: > */ >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 260381
:
230075
|
230246