Revision: 7258
http://svn.sourceforge.net/mahogany/?rev=7258&view=rev
Author: vadz
Date: 2007-04-30 07:46:27 -0700 (Mon, 30 Apr 2007)
Log Message:
-----------
changed _hash_drv_lock_free() to take _ds_lock_t instead of _hash_drv_storage to allow calling it to unlock detached storage map
Modified Paths:
--------------
trunk/M/lib/dspam/src/hash_drv.c
trunk/M/lib/dspam/src/hash_drv.h
Modified: trunk/M/lib/dspam/src/hash_drv.c
===================================================================
--- trunk/M/lib/dspam/src/hash_drv.c 2007-04-30 12:03:04 UTC (rev 7257)
+++ trunk/M/lib/dspam/src/hash_drv.c 2007-04-30 14:46:27 UTC (rev 7258)
@@ -297,7 +297,7 @@
int
_hash_drv_lock_free (
- struct _hash_drv_storage *s,
+ _ds_lock_t *lock,
const char *username)
{
int r;
@@ -305,10 +305,10 @@
if (username == NULL)
return 0;
- r = _ds_release_lock(s->lock);
+ r = _ds_release_lock(*lock);
if (!r) {
- _ds_close_lock(s->lock);
- s->lock = NULL;
+ _ds_close_lock(*lock);
+ *lock = NULL;
} else {
LOG(LOG_ERR, ERR_IO_LOCK_FREE, username, r, strerror(errno));
}
@@ -607,7 +607,7 @@
_hash_drv_close(s->map);
free(s->map);
lock_result =
- _hash_drv_lock_free (s, (CTX->group) ? CTX->group : CTX->username);
+ _hash_drv_lock_free (&s->lock, (CTX->group) ? CTX->group : CTX->username);
if (lock_result < 0)
return EUNKNOWN;
}
Modified: trunk/M/lib/dspam/src/hash_drv.h
===================================================================
--- trunk/M/lib/dspam/src/hash_drv.h 2007-04-30 12:03:04 UTC (rev 7257)
+++ trunk/M/lib/dspam/src/hash_drv.h 2007-04-30 14:46:27 UTC (rev 7258)
@@ -94,7 +94,7 @@
const char *username);
int _hash_drv_lock_free (
- struct _hash_drv_storage *s,
+ _ds_lock_t *lock,
const char *username);
int _hash_drv_open(
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.