| 850 | */ |
| 851 | #ifndef SQLITE_SHELL_FIDDLE |
| 852 | static char *one_input_line(FILE *in, char *zPrior, int isContinuation){ |
| 853 | char *zPrompt; |
| 854 | char *zResult; |
| 855 | if( in!=0 ){ |
| 856 | zResult = local_getline(zPrior, in); |
| 857 | }else{ |
| 858 | zPrompt = isContinuation ? CONTINUATION_PROMPT : mainPrompt; |
| 859 | #if SHELL_USE_LOCAL_GETLINE |
| 860 | printf("%s", zPrompt); |
| 861 | fflush(stdout); |
| 862 | zResult = local_getline(zPrior, stdin); |
| 863 | #else |
| 864 | free(zPrior); |
| 865 | zResult = shell_readline(zPrompt); |
| 866 | if( zResult && *zResult ) shell_add_history(zResult); |
| 867 | #endif |
| 868 | } |
| 869 | return zResult; |
| 870 | } |
| 871 | #endif /* !SQLITE_SHELL_FIDDLE */ |
| 872 | |
| 873 | /* |
no test coverage detected