From issues-return-648-archive-asf-public=cust-asf.ponee.io@avro.apache.org Tue Mar 23 17:23:24 2021 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mxout1-ec2-va.apache.org (mxout1-ec2-va.apache.org [3.227.148.255]) by mx-eu-01.ponee.io (Postfix) with ESMTPS id 732F51804BB for ; Tue, 23 Mar 2021 18:23:24 +0100 (CET) Received: from mail.apache.org (mailroute1-lw-us.apache.org [207.244.88.153]) by mxout1-ec2-va.apache.org (ASF Mail Server at mxout1-ec2-va.apache.org) with SMTP id A5BF14453E for ; Tue, 23 Mar 2021 17:23:18 +0000 (UTC) Received: (qmail 41289 invoked by uid 500); 23 Mar 2021 17:23:18 -0000 Mailing-List: contact issues-help@avro.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@avro.apache.org Delivered-To: mailing list issues@avro.apache.org Received: (qmail 40374 invoked by uid 99); 23 Mar 2021 17:23:16 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 23 Mar 2021 17:23:16 +0000 From: =?utf-8?q?GitBox?= To: issues@avro.apache.org Subject: =?utf-8?q?=5BGitHub=5D_=5Bavro=5D_thiru-mg_commented_on_a_change_in_pull_req?= =?utf-8?q?uest_=231153=3A_AVRO-3051=3A_C++_Reader_and_writers_modernized?= Message-ID: <161652019584.15632.13443739672207619157.asfpy@gitbox.apache.org> Date: Tue, 23 Mar 2021 17:23:15 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit References: In-Reply-To: thiru-mg commented on a change in pull request #1153: URL: https://github.com/apache/avro/pull/1153#discussion_r599780265 ########## File path: lang/c++/impl/DataFile.cc ########## @@ -243,13 +243,13 @@ void DataFileWriterBase::flush() sync(); } -boost::mt19937 random(static_cast(time(0))); +boost::mt19937 random(static_cast(time(nullptr))); DataFileSync DataFileWriterBase::makeSync() { DataFileSync sync; - for (size_t i = 0; i < sync.size(); ++i) { - sync[i] = random(); + for (unsigned char & i : sync) { Review comment: Nice. Thanks, done. -- 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. For queries about this service, please contact Infrastructure at: users@infra.apache.org