chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Modernization
[elogind.git]
/
src
/
vconsole
/
vconsole-setup.c
diff --git
a/src/vconsole/vconsole-setup.c
b/src/vconsole/vconsole-setup.c
index c1f662baa6e6c546526e437c8934049e568ec19d..e11fd589cb3a89a2f005097604bfe8f1dd459af6 100644
(file)
--- a/
src/vconsole/vconsole-setup.c
+++ b/
src/vconsole/vconsole-setup.c
@@
-191,8
+191,8
@@
static void font_copy_to_all_vcs(int fd) {
for (i = 1; i <= 15; i++) {
char vcname[16];
for (i = 1; i <= 15; i++) {
char vcname[16];
- int vcfd;
struct console_font_op cfo;
struct console_font_op cfo;
+ int _cleanup_close_ vcfd = -1;
if (i == vcs.v_active)
continue;
if (i == vcs.v_active)
continue;
@@
-212,8
+212,6
@@
static void font_copy_to_all_vcs(int fd) {
cfo.op = KD_FONT_OP_COPY;
cfo.height = vcs.v_active-1; /* tty1 == index 0 */
ioctl(vcfd, KDFONTOP, &cfo);
cfo.op = KD_FONT_OP_COPY;
cfo.height = vcs.v_active-1; /* tty1 == index 0 */
ioctl(vcfd, KDFONTOP, &cfo);
-
- close_nointr_nofail(vcfd);
}
}
}
}