Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | fixed a double-free() which could happen in one error case. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | json |
Files: | files | file ages | folders |
SHA1: |
65e946c7141c21e218a3da2c407233f2 |
User & Date: | stephan 2011-09-19 18:49:38.198 |
Context
2011-09-19
| ||
19:03 | Moved a db_finalize() which would not have been called in a couple of error cases. ... (check-in: afc1cec6 user: stephan tags: json) | |
18:49 | fixed a double-free() which could happen in one error case. ... (check-in: 65e946c7 user: stephan tags: json) | |
18:48 | Implemented /json/wiki/list (first draft, may change). Pulled in latest cson_sqlite3 additions to simplify the impl. ... (check-in: 5cc88946 user: stephan tags: json) | |
Changes
Changes to src/json.c.
︙ | ︙ | |||
1284 1285 1286 1287 1288 1289 1290 | " FROM tag WHERE tagname GLOB 'wiki-*'" " ORDER BY lower(name)"); listV = cson_value_new_array(); list = cson_value_get_array(listV); while( SQLITE_ROW == db_step(&q) ){ cson_value * v = cson_sqlite3_column_to_value(q.pStmt,0); if(!v){ | < < | | 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 | " FROM tag WHERE tagname GLOB 'wiki-*'" " ORDER BY lower(name)"); listV = cson_value_new_array(); list = cson_value_get_array(listV); while( SQLITE_ROW == db_step(&q) ){ cson_value * v = cson_sqlite3_column_to_value(q.pStmt,0); if(!v){ goto error; }else if( 0 != cson_array_append( list, v ) ){ cson_value_free(v); goto error; } } db_finalize(&q); goto end; error: |
︙ | ︙ |