aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim.Framework/Util.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim.Framework/Util.cs13
1 files changed, 13 insertions, 0 deletions
diff --git a/OpenSim.Framework/Util.cs b/OpenSim.Framework/Util.cs
index 042360d..440ce41 100644
--- a/OpenSim.Framework/Util.cs
+++ b/OpenSim.Framework/Util.cs
@@ -9,6 +9,8 @@ namespace OpenSim.Framework.Utilities
9 public class Util 9 public class Util
10 { 10 {
11 private static Random randomClass = new Random(); 11 private static Random randomClass = new Random();
12 private static uint nextXferID = 10000;
13 private static object XferLock = new object();
12 14
13 public static ulong UIntsToLong(uint X, uint Y) 15 public static ulong UIntsToLong(uint X, uint Y)
14 { 16 {
@@ -23,6 +25,17 @@ namespace OpenSim.Framework.Utilities
23 } 25 }
24 } 26 }
25 27
28 public static uint GetNextXferID()
29 {
30 uint id = 0;
31 lock(XferLock)
32 {
33 id = nextXferID;
34 nextXferID++;
35 }
36 return id;
37 }
38
26 public Util() 39 public Util()
27 { 40 {
28 41