MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:sanja Date:March 3 2008 8:25am
Subject:bk commit into maria tree (bell:1.2616) BUG#34634
View as plain text  
Below is the list of changes that have just been committed into a local
maria repository of bell.  When bell does a push these changes
will be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet@stripped, 2008-03-03 10:25:19+02:00, bell@stripped +1 -0
  Fixed problem of deleting blocks which are being evicted at
  the moment. (BUG#34634)

  storage/maria/ma_pagecache.c@stripped, 2008-03-03 10:25:14+02:00, bell@stripped +14 -0
    Fixed problem of deleting blocks which are being evicted at
    the moment.

diff -Nrup a/storage/maria/ma_pagecache.c b/storage/maria/ma_pagecache.c
--- a/storage/maria/ma_pagecache.c	2008-02-22 23:16:21 +02:00
+++ b/storage/maria/ma_pagecache.c	2008-03-03 10:25:14 +02:00
@@ -1331,6 +1331,7 @@ static void unlink_block(PAGECACHE *page
 {
   DBUG_ENTER("unlink_block");
   DBUG_PRINT("unlink_block", ("unlink 0x%lx", (ulong)block));
+  DBUG_ASSERT(block->next_used != NULL);
   if (block->next_used == block)
   {
     /* The list contains only one member */
@@ -3383,6 +3384,8 @@ restart:
     if (!pagecache->can_be_used)
       goto end;
 
+    DBUG_ASSERT((block->status &
+                 (PCBLOCK_IN_SWITCH | PCBLOCK_REASSIGNED)) == 0);
     if (make_lock_and_pin(pagecache, block, lock, pin))
     {
       /*
@@ -3495,6 +3498,17 @@ restart:
       DBUG_RETURN(0);
     }
     block= page_link->block;
+    if (block->status & (PCBLOCK_REASSIGNED | PCBLOCK_IN_SWITCH))
+    {
+      DBUG_PRINT("info", ("Block 0x%0lx already is %s",
+                          (ulong) block,
+                          ((block->status & PCBLOCK_REASSIGNED) ?
+                           "reassigned" : "in switch")));
+      PCBLOCK_INFO(block);
+      /* The block (will be | is) flushed and we can't prevent it */
+      page_link->requests--;
+      goto end;
+    }
     /* See NOTE for pagecache_unlock about registering requests. */
     if (pin == PAGECACHE_PIN)
       reg_requests(pagecache, block, 1);
Thread
bk commit into maria tree (bell:1.2616) BUG#34634sanja3 Mar
  • Re: bk commit into maria tree (bell:1.2616) BUG#34634Guilhem Bichot3 Mar
    • Re: bk commit into maria tree (bell:1.2616) BUG#34634Sanja Byelkin3 Mar
      • Re: bk commit into maria tree (bell:1.2616) BUG#34634Guilhem Bichot4 Mar