projects
/
debian
/
gcpegg
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
prepare to upload
[debian/gcpegg]
/
reg_pear.c
diff --git
a/reg_pear.c
b/reg_pear.c
index bc79bb702920bd432bfb6ba07a5a38ccf613505d..0ff329959eb4735ff53c52f09a403bd1adda84f9 100644
(file)
--- a/
reg_pear.c
+++ b/
reg_pear.c
@@
-77,7
+77,7
@@
static int32 OpenDev(DevOpts *opts) {
sprintf(ttydev, "/dev/term/%c", 'a' + (opts->port - 1));
#endif
#else
sprintf(ttydev, "/dev/term/%c", 'a' + (opts->port - 1));
#endif
#else
- sprintf(ttydev, "/dev/
ttyS%d
", opts->port);
+ sprintf(ttydev, "/dev/
REG
", opts->port);
#endif
switch(opts->baud) {
#endif
switch(opts->baud) {
@@
-91,11
+91,11
@@
static int32 OpenDev(DevOpts *opts) {
case 115200: baudcon = B115200; break;
#endif
default:
case 115200: baudcon = B115200; break;
#endif
default:
- printf("%s: Baud rate %
l
d not supported.\n", pgmname, opts->baud);
+ printf("%s: Baud rate %d not supported.\n", pgmname, opts->baud);
return -1;
}
return -1;
}
- fprintf(stderr, "Opening %s at %
l
d\n", ttydev, opts->baud);
+ fprintf(stderr, "Opening %s at %d\n", ttydev, opts->baud);
if ((TTY_fd = open(ttydev, O_RDONLY
#ifdef CPU_BOUND
| O_NDELAY
if ((TTY_fd = open(ttydev, O_RDONLY
#ifdef CPU_BOUND
| O_NDELAY
@@
-122,7
+122,9
@@
static int32 OpenDev(DevOpts *opts) {
#else
res = cfsetospeed(&tt, baudcon);
cfmakeraw(&tt);
#else
res = cfsetospeed(&tt, baudcon);
cfmakeraw(&tt);
+#if !defined(__FreeBSD_kernel__)
tt.c_oflag &= (~(TABDLY | ONLCR));
tt.c_oflag &= (~(TABDLY | ONLCR));
+#endif
#endif
res = tcsetattr(TTY_fd, TCSANOW, &tt);
#endif
res = tcsetattr(TTY_fd, TCSANOW, &tt);