** Print an error message for the .ar command to stderr and return ** SQLITE_ERROR. */
| 16201 | ** SQLITE_ERROR. |
| 16202 | */ |
| 16203 | static int arErrorMsg(ArCommand *pAr, const char *zFmt, ...){ |
| 16204 | va_list ap; |
| 16205 | char *z; |
| 16206 | va_start(ap, zFmt); |
| 16207 | z = sqlite3_vmprintf(zFmt, ap); |
| 16208 | va_end(ap); |
| 16209 | utf8_printf(stderr, "Error: %s\n", z); |
| 16210 | if( pAr->fromCmdLine ){ |
| 16211 | utf8_printf(stderr, "Use \"-A\" for more help\n"); |
| 16212 | }else{ |
| 16213 | utf8_printf(stderr, "Use \".archive --help\" for more help\n"); |
| 16214 | } |
| 16215 | sqlite3_free(z); |
| 16216 | return SQLITE_ERROR; |
| 16217 | } |
| 16218 | |
| 16219 | /* |
| 16220 | ** Values for ArCommand.eCmd. |
no test coverage detected