/ Check-in [afbe9023]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix a Windows line ending issue in a test case that was causing an incrblob test to fail.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: afbe9023a706375be53bce389ef4e806f17fc7ec
User & Date: shaneh 2011-06-24 13:50:13
Context
2011-06-24
18:43
Explicitly cast an argument to printf() to (int), in case the result of the pointer arithmetic expression is a 64-bit integer on some platforms. check-in: 90cfeaf7 user: dan tags: trunk
13:50
Fix a Windows line ending issue in a test case that was causing an incrblob test to fail. check-in: afbe9023 user: shaneh tags: trunk
11:29
Fix some harmless compiler warnings that were occurring with THREADSAFE=0. check-in: 9b191bb4 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to test/incrblob_err.test.

    31     31     set bytes [file size [info script]]
    32     32     execsql {
    33     33       CREATE TABLE blobs(k, v BLOB);
    34     34       INSERT INTO blobs VALUES(1, zeroblob($::bytes));
    35     35     }
    36     36   } -tclbody {
    37     37     set ::blob [db incrblob blobs v 1]
           38  +  fconfigure $::blob -translation binary
    38     39     set rc [catch {puts -nonewline $::blob $::data}]
    39     40     if {$rc} { error "out of memory" }
    40     41   } 
    41     42   
    42     43   do_malloc_test 2 -tclprep {
    43     44     execsql {
    44     45       CREATE TABLE blobs(k, v BLOB);
................................................................................
    67     68     } elseif {$::r ne $::data} {
    68     69       error "Bad data read..."
    69     70     }
    70     71     set rc [catch {close $::blob}]
    71     72     if {$rc} { 
    72     73       error "out of memory" 
    73     74     }
    74         -} 
    75         -
           75  +}
    76     76   
    77     77   do_ioerr_test incrblob_err-4 -cksum 1 -sqlprep {
    78     78     CREATE TABLE blobs(k, v BLOB);
    79     79     INSERT INTO blobs VALUES(1, $::data);
    80     80   } -tclbody {
    81     81     set ::blob [db incrblob blobs v 1]
    82     82     read $::blob
................................................................................
    83     83   }
    84     84   
    85     85   do_ioerr_test incrblob_err-5 -cksum 1 -sqlprep {
    86     86     CREATE TABLE blobs(k, v BLOB);
    87     87     INSERT INTO blobs VALUES(1, zeroblob(length(CAST($::data AS BLOB))));
    88     88   } -tclbody {
    89     89     set ::blob [db incrblob blobs v 1]
           90  +  fconfigure $::blob -translation binary
    90     91     puts -nonewline $::blob $::data
    91     92     close $::blob
    92     93   }
    93     94   
    94     95   do_ioerr_test incrblob_err-6 -cksum 1 -sqlprep {
    95     96     CREATE TABLE blobs(k, v BLOB);
    96     97     INSERT INTO blobs VALUES(1, $::data || $::data || $::data);
    97     98   } -tclbody {
    98     99     set ::blob [db incrblob blobs v 1]
          100  +  fconfigure $::blob -translation binary
    99    101     seek $::blob -20 end
   100    102     puts -nonewline $::blob "12345678900987654321"
   101    103     close $::blob
   102    104   }
   103    105   
   104    106   do_ioerr_test incrblob_err-7 -cksum 1 -sqlprep {
   105    107     PRAGMA auto_vacuum = 1;