util/uuid.lua

Thu, 23 Oct 2008 03:52:51 +0100

author
Matthew Wild <mwild1@gmail.com>
date
Thu, 23 Oct 2008 03:52:51 +0100
changeset 119
b48a573608e8
parent 44
80d2ade0fd69
child 145
fbb3a4ff9cf1
permissions
-rw-r--r--

Relocate presence broadcast to core_handle_stanza()
which is for processing stanzas that the server must handle (not route)

44
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
1
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
2 local m_random = math.random;
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
3 module "uuid"
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
4
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
5 function uuid_generate()
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
6 return m_random(0, 99999999);
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
7 end
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
8
80d2ade0fd69 Add "uuid" library and make sessionmanager use this.
Matthew Wild <mwild1@gmail.com>
parents:
diff changeset
9 return _M;

mercurial