summaryrefslogtreecommitdiffstats
path: root/source/lib/system.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1996-10-02 14:09:22 +0000
committerAndrew Tridgell <tridge@samba.org>1996-10-02 14:09:22 +0000
commit20b6203dac4bbb43e4e7bea0b214496d76d679d9 (patch)
tree173087b470d3f84f26cc57d5b6e067fda3152d4c /source/lib/system.c
parentb6c1c60d72e1625ca172b8f8eb07078413611468 (diff)
downloadsamba-20b6203dac4bbb43e4e7bea0b214496d76d679d9.tar.gz
samba-20b6203dac4bbb43e4e7bea0b214496d76d679d9.tar.xz
samba-20b6203dac4bbb43e4e7bea0b214496d76d679d9.zip
- a huge pile of changes from Luke which implement the browse.conf
stuff and also fix a pile of nmbd bugs. Unfortunately I found it very hard to disentangle the new features from the bug fixes so I am putting in the new code. I hope this is the last big pile of changes to the 1.9.16 series!
Diffstat (limited to 'source/lib/system.c')
-rw-r--r--source/lib/system.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/source/lib/system.c b/source/lib/system.c
index 81e9a6679ad..f6b916881bf 100644
--- a/source/lib/system.c
+++ b/source/lib/system.c
@@ -116,6 +116,15 @@ int sys_unlink(char *fname)
/*******************************************************************
+random number generator
+********************************************************************/
+unsigned int sys_random(int max_range)
+{
+ return(((unsigned int)random()) % max_range);
+}
+
+
+/*******************************************************************
a simple open() wrapper
********************************************************************/
int sys_open(char *fname,int flags,int mode)