[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r5178 - GNUnet/src/applications/fs/module
From: |
gnunet |
Subject: |
[GNUnet-SVN] r5178 - GNUnet/src/applications/fs/module |
Date: |
Fri, 29 Jun 2007 02:15:07 -0600 (MDT) |
Author: grothoff
Date: 2007-06-29 02:15:07 -0600 (Fri, 29 Jun 2007)
New Revision: 5178
Modified:
GNUnet/src/applications/fs/module/fs.c
Log:
avoid content duplication
Modified: GNUnet/src/applications/fs/module/fs.c
===================================================================
--- GNUnet/src/applications/fs/module/fs.c 2007-06-29 07:55:39 UTC (rev
5177)
+++ GNUnet/src/applications/fs/module/fs.c 2007-06-29 08:15:07 UTC (rev
5178)
@@ -353,8 +353,15 @@
&ri[1],
ntohs(req->size) - sizeof(CS_fs_request_insert_MESSAGE));
MUTEX_LOCK(lock);
- ret = datastore->put(&query,
- datum);
+ if ( (type != D_BLOCK) ||
+ (0 == datastore->get(&query,
+ type,
+ NULL,
+ NULL)) )
+ ret = datastore->put(&query,
+ datum);
+ else
+ ret = OK;
MUTEX_UNLOCK(lock);
if ( (ntohl(ri->anonymityLevel) == 0) &&
(dht != NULL) ) {
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r5178 - GNUnet/src/applications/fs/module,
gnunet <=