Skip to content

Commit ca0192c

Browse files
committed
fix core password callback
1 parent 01c3efd commit ca0192c

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

app/src/main/cpp/CoreWrapper.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,11 +119,11 @@ Java_at_tomtasche_reader_background_CoreWrapper_parseNative(JNIEnv *env, jobject
119119
config.text_document_margin = true;
120120
}
121121

122-
html = odr::OpenDocumentReader::html(inputPathCpp, [&passwordCpp]() -> const char * {
122+
html = odr::OpenDocumentReader::html(inputPathCpp, [&passwordCpp]() -> std::string {
123123
if (passwordCpp.has_value()) {
124-
return passwordCpp.value().c_str();
124+
return passwordCpp.value();
125125
}
126-
return nullptr;
126+
return "";
127127
}, outputPathCpp, config);
128128

129129
{

0 commit comments

Comments
 (0)