Index: uspace/srv/fs/fat/fat_ops.c
===================================================================
--- uspace/srv/fs/fat/fat_ops.c	(revision 4098e388e474a3d5cc6daba81339f5102aa1273b)
+++ uspace/srv/fs/fat/fat_ops.c	(revision 4b4668e50d198088fac7dd92f331c46d4657a01d)
@@ -445,5 +445,8 @@
 	for (i = 0; i < blocks; i++) {
 		rc = fat_block_get(&b, bs, parentp, i, BLOCK_FLAGS_NONE);
-		assert(rc == EOK);
+		if (rc != EOK) {
+			fibril_mutex_unlock(&parentp->idx->lock);
+			return rc;
+		}
 		for (j = 0; j < dps; j++) {
 			d = ((fat_dentry_t *)b->data) + j;
@@ -460,5 +463,8 @@
 		}
 		rc = block_put(b);
-		assert(rc == EOK);
+		if (rc != EOK) {
+			fibril_mutex_unlock(&parentp->idx->lock);
+			return rc;
+		}
 	}
 	j = 0;
@@ -478,11 +484,20 @@
 	}
 	rc = fat_zero_cluster(bs, parentp->idx->dev_handle, mcl);
-	assert(rc == EOK);
+	if (rc != EOK) {
+		fibril_mutex_unlock(&parentp->idx->lock);
+		return rc;
+	}
 	rc = fat_append_clusters(bs, parentp, mcl);
-	assert(rc == EOK);
+	if (rc != EOK) {
+		fibril_mutex_unlock(&parentp->idx->lock);
+		return rc;
+	}
 	parentp->size += bps * bs->spc;
 	parentp->dirty = true;		/* need to sync node */
 	rc = fat_block_get(&b, bs, parentp, i, BLOCK_FLAGS_NONE);
-	assert(rc == EOK);
+	if (rc != EOK) {
+		fibril_mutex_unlock(&parentp->idx->lock);
+		return rc;
+	}
 	d = (fat_dentry_t *)b->data;
 
@@ -498,6 +513,7 @@
 	b->dirty = true;		/* need to sync block */
 	rc = block_put(b);
-	assert(rc == EOK);
 	fibril_mutex_unlock(&parentp->idx->lock);
+	if (rc != EOK) 
+		return rc;
 
 	fibril_mutex_lock(&childp->idx->lock);
@@ -510,5 +526,11 @@
 	 */
 	rc = fat_block_get(&b, bs, childp, 0, BLOCK_FLAGS_NONE);
-	assert(rc == EOK);
+	if (rc != EOK) {
+		/*
+		 * Rather than returning an error, simply skip the creation of
+		 * these two entries.
+		 */
+		goto skip_dots;
+	}
 	d = (fat_dentry_t *)b->data;
 	if (fat_classify_dentry(d) == FAT_DENTRY_LAST ||
@@ -534,6 +556,10 @@
 	}
 	b->dirty = true;		/* need to sync block */
-	rc = block_put(b);
-	assert(rc == EOK);
+	/*
+	 * Ignore the return value as we would have fallen through on error
+	 * anyway.
+	 */
+	(void) block_put(b);
+skip_dots:
 
 	childp->idx->pfc = parentp->firstc;
