io-console 0.5.2 → 0.5.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/ext/io/console/console.c +5 -3
  3. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f87daa288fc605a3bf48b70558316f9427552fcf895e3a40363f71ba095d3e1b
4
- data.tar.gz: bddde3f65430cad405fdd4ef576f9d18b85368001f5ea27dc16fb941e0065a04
3
+ metadata.gz: 9474fd3d0f8b7760a83e50da0e69ba4e018e96935018a22b933a3f9eec648a5b
4
+ data.tar.gz: dc4f448e975155e39360f95f4442f1c54e067821183e6214e5fd2a5475504879
5
5
  SHA512:
6
- metadata.gz: bd7bb0e4285b7a3de96006386f262cc74fde97fc34a157ad8b834661e52a1aefe210d683c8264e6a98cf8ce80610b7fa8917e79d2b80f87ea4ae052e60c98839
7
- data.tar.gz: 23a0ac10ecd3f77ca899f5c00a9cc0689bc1c593540b116a6656eaef7d50aad887a3cfbcd66e6f954ebcac3e93f7f9eddbcda0f620d7804a196d541359e230bc
6
+ metadata.gz: 7734614638324ebd6fdf96518d897ebb3e497fae56f5be84d2fbf5098a14923c19445166ccacfa4fcfcdc0a4ea9bdef5c16e627416f44b0d1a7ac93e06b8c073
7
+ data.tar.gz: 8bd122615986429eba3668a56e420a5a242c7d80617b8960566426a99f85c56b80fa5089eb5078016aec36cc5b548a49d7ec44e52699555847e06380359dd36d
@@ -23,7 +23,7 @@ typedef struct termios conmode;
23
23
  static int
24
24
  setattr(int fd, conmode *t)
25
25
  {
26
- while (tcsetattr(fd, TCSAFLUSH, t)) {
26
+ while (tcsetattr(fd, TCSANOW, t)) {
27
27
  if (errno != EINTR) return 0;
28
28
  }
29
29
  return 1;
@@ -165,11 +165,13 @@ set_rawmode(conmode *t, void *arg)
165
165
  cfmakeraw(t);
166
166
  t->c_lflag &= ~(ECHOE|ECHOK);
167
167
  #elif defined HAVE_TERMIOS_H || defined HAVE_TERMIO_H
168
- t->c_iflag &= ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON);
168
+ t->c_iflag &= ~(IGNBRK|BRKINT|IGNPAR|PARMRK|INPCK|ISTRIP|INLCR|IGNCR|ICRNL|IXON|IXOFF|IXANY|IMAXBEL);
169
169
  t->c_oflag &= ~OPOST;
170
- t->c_lflag &= ~(ECHO|ECHOE|ECHOK|ECHONL|ICANON|ISIG|IEXTEN);
170
+ t->c_lflag &= ~(ECHO|ECHOE|ECHOK|ECHONL|ICANON|ISIG|IEXTEN|XCASE);
171
171
  t->c_cflag &= ~(CSIZE|PARENB);
172
172
  t->c_cflag |= CS8;
173
+ t->c_cc[VMIN] = 1;
174
+ t->c_cc[VTIME] = 0;
173
175
  #elif defined HAVE_SGTTY_H
174
176
  t->sg_flags &= ~ECHO;
175
177
  t->sg_flags |= RAW;
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: io-console
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nobu Nakada
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-10 00:00:00.000000000 Z
11
+ date: 2019-07-25 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: add console capabilities to IO instances.
14
14
  email: nobu@ruby-lang.org
@@ -43,7 +43,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
43
43
  - !ruby/object:Gem::Version
44
44
  version: '0'
45
45
  requirements: []
46
- rubygems_version: 3.1.0.pre3
46
+ rubygems_version: 3.1.1
47
47
  signing_key:
48
48
  specification_version: 4
49
49
  summary: Console interface