summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/include/serverid.h2
-rw-r--r--source3/lib/serverid.c21
-rw-r--r--source3/lib/util.c21
3 files changed, 23 insertions, 21 deletions
diff --git a/source3/include/serverid.h b/source3/include/serverid.h
index 1833f53d55..ed8d17f95a 100644
--- a/source3/include/serverid.h
+++ b/source3/include/serverid.h
@@ -75,4 +75,6 @@ bool serverid_parent_init(TALLOC_CTX *mem_ctx);
*/
uint64_t serverid_get_random_unique_id(void);
+bool serverid_equal(const struct server_id *p1, const struct server_id *p2);
+
#endif
diff --git a/source3/lib/serverid.c b/source3/lib/serverid.c
index 48d5b4251a..0033d60833 100644
--- a/source3/lib/serverid.c
+++ b/source3/lib/serverid.c
@@ -453,3 +453,24 @@ uint64_t serverid_get_random_unique_id(void)
return unique_id;
}
+
+bool serverid_equal(const struct server_id *p1, const struct server_id *p2)
+{
+ if (p1->pid != p2->pid) {
+ return false;
+ }
+
+ if (p1->task_id != p2->task_id) {
+ return false;
+ }
+
+ if (p1->vnn != p2->vnn) {
+ return false;
+ }
+
+ if (p1->unique_id != p2->unique_id) {
+ return false;
+ }
+
+ return true;
+}
diff --git a/source3/lib/util.c b/source3/lib/util.c
index 653fff5c64..f1b815878d 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -2058,27 +2058,6 @@ struct server_id *new_server_id_task(TALLOC_CTX *mem_ctx)
return server_id;
}
-bool serverid_equal(const struct server_id *p1, const struct server_id *p2)
-{
- if (p1->pid != p2->pid) {
- return false;
- }
-
- if (p1->task_id != p2->task_id) {
- return false;
- }
-
- if (p1->vnn != p2->vnn) {
- return false;
- }
-
- if (p1->unique_id != p2->unique_id) {
- return false;
- }
-
- return true;
-}
-
bool procid_is_me(const struct server_id *pid)
{
if (pid->pid != getpid())