|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From 440046e9220aa418ac0ffbdf126512b3341dce23 Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From: David Herrmann <dh.herrmann@gmail.com>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Date: Mon, 15 Sep 2014 17:12:41 +0200
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Subject: [PATCH] terminal: fix missing hashmap_new() conversions
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
hashmap_new() now takes *_ops instead of individual functions. Fix up any
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
missing invokations of it that haven't been converted already.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
---
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
src/libsystemd-terminal/idev.c | 8 ++++----
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
src/libsystemd-terminal/sysview.c | 10 +++++-----
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
2 files changed, 9 insertions(+), 9 deletions(-)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/src/libsystemd-terminal/idev.c b/src/libsystemd-terminal/idev.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index d37e0313e4..8592930662 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/src/libsystemd-terminal/idev.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/src/libsystemd-terminal/idev.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -454,11 +454,11 @@ int idev_session_new(idev_session **out,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return r;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
}
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- s->element_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ s->element_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!s->element_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- s->device_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ s->device_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!s->device_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -647,11 +647,11 @@ int idev_context_new(idev_context **out, sd_event *event, sd_bus *sysbus) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (sysbus)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
c->sysbus = sd_bus_ref(sysbus);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- c->session_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ c->session_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!c->session_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- c->data_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ c->data_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!c->data_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/src/libsystemd-terminal/sysview.c b/src/libsystemd-terminal/sysview.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index bd345fa22e..2083f5a7e0 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/src/libsystemd-terminal/sysview.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/src/libsystemd-terminal/sysview.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -368,11 +368,11 @@ int sysview_seat_new(sysview_seat **out, sysview_context *c, const char *name) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!seat->name)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- seat->session_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ seat->session_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!seat->session_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- seat->device_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ seat->device_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!seat->device_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -767,15 +767,15 @@ int sysview_context_new(sysview_context **out,
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return errno > 0 ? -errno : -EFAULT;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
}
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- c->seat_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ c->seat_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!c->seat_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- c->session_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ c->session_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!c->session_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- c->device_map = hashmap_new(string_hash_func, string_compare_func);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ c->device_map = hashmap_new(&string_hash_ops);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (!c->device_map)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|