mapleFU commented on code in PR #43222: URL: https://github.com/apache/arrow/pull/43222#discussion_r1674172006
########## cpp/src/parquet/encryption/internal_file_encryptor.cc: ########## @@ -150,8 +150,8 @@ encryption::AesEncryptor* InternalFileEncryptor::GetMetaAesEncryptor( int key_len = static_cast<int>(key_size); int index = MapKeyLenToEncryptorArrayIndex(key_len); if (meta_encryptor_[index] == nullptr) { - meta_encryptor_[index].reset( - encryption::AesEncryptor::Make(algorithm, key_len, true, &all_encryptors_)); + meta_encryptor_[index] = encryption::AesEncryptor::Make(algorithm, key_len, true); + all_encryptors_.push_back(meta_encryptor_[index].get()); Review Comment: `GetMetaAesEncryptor` does a nullable check, I wonder would we face the case that we didn't use it but it being WipeOut -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org