summaryrefslogtreecommitdiff
path: root/foreign
diff options
context:
space:
mode:
authormalosek <malosek@fastmq.com>2009-10-05 10:18:24 +0200
committermalosek <malosek@fastmq.com>2009-10-05 10:18:24 +0200
commite1b9fcd4b185cdcfd460a5d2ecb29d085856bb20 (patch)
treed4443a9756a5739a069307f49d4b5b72cc22d3d9 /foreign
parent64e68e748607473befbcf2d96590d45dc7bc98db (diff)
moved pgm_create_custom_gsi into PGM1 and drop ssl dependency
Diffstat (limited to 'foreign')
-rw-r--r--foreign/openpgm/create_custom_gsi.patch43
-rw-r--r--foreign/openpgm/lost_data_tsi.patch4
2 files changed, 45 insertions, 2 deletions
diff --git a/foreign/openpgm/create_custom_gsi.patch b/foreign/openpgm/create_custom_gsi.patch
new file mode 100644
index 0000000..2e709f1
--- /dev/null
+++ b/foreign/openpgm/create_custom_gsi.patch
@@ -0,0 +1,43 @@
+--- foreign/openpgm/libpgm-1.2.14/openpgm/pgm/include/pgm/gsi.h 2009-08-27 04:53:23.000000000 +0200
++++ foreign/openpgm/libpgm-1.2.14/openpgm/pgm/include/pgm/gsi.h 2009-10-05 09:29:21.765126004 +0200
+@@ -42,6 +42,7 @@
+
+ int pgm_create_md5_gsi (pgm_gsi_t*);
+ int pgm_create_ipv4_gsi (pgm_gsi_t*);
++int pgm_create_custom_gsi (const char *string_, pgm_gsi_t*);
+
+ int pgm_print_gsi_r (const pgm_gsi_t*, char*, gsize);
+ gchar* pgm_print_gsi (const pgm_gsi_t*);
+
+--- foreign/openpgm/libpgm-1.2.14/openpgm/pgm/gsi.c 2009-08-27 04:53:25.000000000 +0200
++++ foreign/openpgm/libpgm-1.2.14/openpgm/pgm/gsi.c 2009-10-05 09:28:47.113125069 +0200
+@@ -430,6 +430,28 @@
+ return retval;
+ }
+
++/* create a global session ID as low order 48 bits of md5 of the string. */
++int
++pgm_create_custom_gsi (
++ const char *string_,
++ pgm_gsi_t* gsi_
++ )
++{
++ g_return_val_if_fail (gsi_ != NULL, -EINVAL);
++
++ struct md5_ctx ctx;
++ char resblock [16];
++
++ md5_init_ctx (&ctx);
++ md5_process_bytes (string_, strlen (string_), &ctx);
++ md5_finish_ctx (&ctx, resblock);
++
++ memcpy (gsi_, resblock + 10, 6);
++
++ return 0;
++}
++
++
+ /* re-entrant form of pgm_print_gsi()
+ */
+ int
+
diff --git a/foreign/openpgm/lost_data_tsi.patch b/foreign/openpgm/lost_data_tsi.patch
index bfd4425..6bfe02f 100644
--- a/foreign/openpgm/lost_data_tsi.patch
+++ b/foreign/openpgm/lost_data_tsi.patch
@@ -1,4 +1,4 @@
---- libpgm-1.2.14/openpgm/pgm/transport.c 2009-08-27 04:54:04.000000000 +0200
+--- foreign/openpgm/libpgm-1.2.14/openpgm/pgm/transport.c 2009-08-27 04:54:04.000000000 +0200
+++ foreign/openpgm/libpgm-1.2.14/openpgm/pgm/transport.c 2009-09-22 14:36:07.713124619 +0200
@@ -2342,6 +2342,7 @@
if (waiting_rxw->ack_cumulative_losses != waiting_rxw->cumulative_losses)
@@ -64,7 +64,7 @@
rxw->pgm_sock_err.lost_count = rxw->cumulative_losses - rxw->ack_cumulative_losses;
rxw->ack_cumulative_losses = rxw->cumulative_losses;
---- libpgm-1.2.14/openpgm/pgm/include/pgm/transport.h 2009-08-27 04:53:23.000000000 +0200
+--- foreign/openpgm/libpgm-1.2.14/openpgm/pgm/include/pgm/transport.h 2009-08-27 04:53:23.000000000 +0200
+++ foreign/openpgm/libpgm-1.2.14/openpgm/pgm/include/pgm/transport.h 2009-09-21 15:49:36.000000000 +0200
@@ -205,6 +205,7 @@
gboolean is_bound;