** Print an error message for the .ar command to stderr and return ** SQLITE_ERROR. */
| 21955 | ** SQLITE_ERROR. |
| 21956 | */ |
| 21957 | static int arErrorMsg(ArCommand *pAr, const char *zFmt, ...){ |
| 21958 | va_list ap; |
| 21959 | char *z; |
| 21960 | va_start(ap, zFmt); |
| 21961 | z = sqlite3_vmprintf(zFmt, ap); |
| 21962 | va_end(ap); |
| 21963 | utf8_printf(stderr, "Error: %s\n", z); |
| 21964 | if( pAr->fromCmdLine ){ |
| 21965 | utf8_printf(stderr, "Use \"-A\" for more help\n"); |
| 21966 | }else{ |
| 21967 | utf8_printf(stderr, "Use \".archive --help\" for more help\n"); |
| 21968 | } |
| 21969 | sqlite3_free(z); |
| 21970 | return SQLITE_ERROR; |
| 21971 | } |
| 21972 | |
| 21973 | /* |
| 21974 | ** Values for ArCommand.eCmd. |
no test coverage detected