src/relpipe-in-asn1.cpp
branchv_0
changeset 10 db8429c641c6
parent 2 7128fabeede0
equal deleted inserted replaced
9:7d309accc639 10:db8429c641c6
    51 		ASN1Command command;
    51 		ASN1Command command;
    52 		std::shared_ptr<RelationalWriter> writer(Factory::create(std::cout));
    52 		std::shared_ptr<RelationalWriter> writer(Factory::create(std::cout));
    53 		command.process(cin, writer, configuration);
    53 		command.process(cin, writer, configuration);
    54 		resultCode = CLI::EXIT_CODE_SUCCESS;
    54 		resultCode = CLI::EXIT_CODE_SUCCESS;
    55 	} catch (RelpipeWriterException& e) {
    55 	} catch (RelpipeWriterException& e) {
    56 		fwprintf(stderr, L"Caught Writer exception: %ls\n", e.getMessge().c_str());
    56 		fwprintf(stderr, L"Caught Writer exception: %ls\n", e.getMessage().c_str());
    57 		fwprintf(stderr, L"Debug: Input stream: eof=%ls, lastRead=%d\n", (cin.eof() ? L"true" : L"false"), cin.gcount());
    57 		fwprintf(stderr, L"Debug: Input stream: eof=%ls, lastRead=%d\n", (cin.eof() ? L"true" : L"false"), cin.gcount());
    58 		resultCode = CLI::EXIT_CODE_DATA_ERROR;
    58 		resultCode = CLI::EXIT_CODE_DATA_ERROR;
    59 	} catch (RelpipeCLIException& e) {
    59 	} catch (RelpipeCLIException& e) {
    60 		fwprintf(stderr, L"Caught CLI exception: %ls\n", e.getMessge().c_str());
    60 		fwprintf(stderr, L"Caught CLI exception: %ls\n", e.getMessage().c_str());
    61 		fwprintf(stderr, L"Debug: Input stream: eof=%ls, lastRead=%d\n", (cin.eof() ? L"true" : L"false"), cin.gcount());
    61 		fwprintf(stderr, L"Debug: Input stream: eof=%ls, lastRead=%d\n", (cin.eof() ? L"true" : L"false"), cin.gcount());
    62 		resultCode = e.getExitCode();
    62 		resultCode = e.getExitCode();
    63 	}
    63 	}
    64 
    64 
    65 	return resultCode;
    65 	return resultCode;