projects
/
qemu.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7ee3bf0
)
vnc/spice: fix "never" and "now" expire_time
author
Marc-André Lureau
<marcandre.lureau@redhat.com>
Thu, 6 Jan 2011 10:43:17 +0000
(11:43 +0100)
committer
Gerd Hoffmann
<kraxel@redhat.com>
Mon, 24 Jan 2011 14:13:54 +0000
(15:13 +0100)
monitor.c
patch
|
blob
|
history
diff --git
a/monitor.c
b/monitor.c
index 4c92d38d9efa0bef32cdd2c8560a8ab13182b2d8..6aa1bb99ef489d8e02c96ce7fcb03abbb667c1cc 100644
(file)
--- a/
monitor.c
+++ b/
monitor.c
@@
-1136,9
+1136,9
@@
static int expire_password(Monitor *mon, const QDict *qdict, QObject **ret_data)
time_t when;
int rc;
- if (strcmp(whenstr, "now")) {
+ if (strcmp(whenstr, "now")
== 0
) {
when = 0;
- } else if (strcmp(whenstr, "never")) {
+ } else if (strcmp(whenstr, "never")
== 0
) {
when = TIME_MAX;
} else if (whenstr[0] == '+') {
when = time(NULL) + strtoull(whenstr+1, NULL, 10);