From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 295756F3C4; Mon, 10 May 2021 21:41:56 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 295756F3C4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1620672116; bh=7i44iSqwWtO7ub6c4dMdunaAFSMGPEZ7QYKFhKAB1MI=; h=To:References:Date:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=iMEUn7YxXpEJBmvyuhs9EUVei4HBHvuSuB/OKlOAmKbF/AixZ/e2UazSS6sjoBmwg fkOpWgiFDE38Ve6yi0k8JbIgdrVQXpvuq+XpvgVTJaLvUwIs80Va+A33MvYta40FNe 1d1VkIBp2QwGb53QjPQNT31baqcMwa2OFnj7DGu0= Received: from smtp48.i.mail.ru (smtp48.i.mail.ru [94.100.177.108]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 798746F3C4 for ; Mon, 10 May 2021 21:40:33 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 798746F3C4 Received: by smtp48.i.mail.ru with esmtpa (envelope-from ) id 1lgApV-0003u6-1h; Mon, 10 May 2021 21:40:33 +0300 To: Cyrill Gorcunov , tml References: <20210504155819.290874-1-gorcunov@gmail.com> <20210504155819.290874-10-gorcunov@gmail.com> Message-ID: <3454dc30-572a-40c7-8d3b-f0cd0df84721@tarantool.org> Date: Mon, 10 May 2021 20:40:32 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 MIME-Version: 1.0 In-Reply-To: <20210504155819.290874-10-gorcunov@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD95978C26455E69BE0ABDB394FB841241C41AA4B146174B5D1182A05F5380850402A0DA84130CB5E17303D465D531EF4BF2C8E6C604E7B33E7DB12447300FA7F78 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE78E8764B5BC580342EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637539FDAA91738A5BD8638F802B75D45FF914D58D5BE9E6BC1A93B80C6DEB9DEE97C6FB206A91F05B2E1E4294B994819E7A44DE2FBEA65BF5489428004B1FE94FDD2E47CDBA5A96583C09775C1D3CA48CFA333A05395E4745B117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658378DA827A17800CE75A31C54DA8CF07A79FA2833FD35BB23DF004C90652538430302FCEF25BFAB3454AD6D5ED66289B5278DA827A17800CE7498DF72B8374A261D32BA5DBAC0009BE395957E7521B51C20BC6067A898B09E4090A508E0FED6299176DF2183F8FC7C0389A5E40700E7A7ECD04E86FAF290E2D7E9C4E3C761E06A71DD303D21008E29813377AFFFEAFD269A417C69337E82CC2E827F84554CEF50127C277FBC8AE2E8BA83251EDC214901ED5E8D9A59859A8B613439FA09F3DCB32089D37D7C0E48F6C5571747095F342E88FB05168BE4CE3AF X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2368A440D3B0F6089093C9A16E5BC824A2A04A2ABAA09D25379311020FFC8D4AD06F486128ED73FA71EB981E1FE9F70CC X-C1DE0DAB: 0D63561A33F958A55D518B4BCB1E345311F120DE83BA76E921ABE2073E47F144D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA7502E6951B79FF9A3F410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34AEC7C2AC3C44791D34505581A0EED575EE8AE7353D1CC93D79ABEC59D0DF7942419588B5E24A7B8A1D7E09C32AA3244CA12376E7EC5F66B2035530704B8E6430C86C126E7119A0FE729B2BEF169E0186 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojW8rfvRc3+Aplpy0VXEOTFQ== X-Mailru-Sender: 504CC1E875BF3E7D9BC0E5172ADA311024A4BC108AE990B248AB188BFA02BFBFD586A72D9E53DC1D07784C02288277CA03E0582D3806FB6A5317862B1921BA260ED6CFD6382C13A6112434F685709FCF0DA7A0AF5A3A8387 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v3 09/10] wal: fix say_x format X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Vladislav Shpilevoy via Tarantool-patches Reply-To: Vladislav Shpilevoy Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Good job on the patch! > diff --git a/src/box/wal.c b/src/box/wal.c > index 6468df884..fff530a38 100644 > --- a/src/box/wal.c > +++ b/src/box/wal.c > @@ -1009,13 +1009,14 @@ wal_assign_lsn(struct vclock *vclock_diff, struct vclock *base, > int64_t diff = (*row)->lsn - vclock_get(base, (*row)->replica_id); > if (diff <= vclock_get(vclock_diff, > (*row)->replica_id)) { > + int64_t confirmed_lsn = > + vclock_get(base, (*row)->replica_id) + > + vclock_get(vclock_diff, (*row)->replica_id); > say_crit("Attempt to write a broken LSN to WAL:" > - " replica id: %d, confirmed lsn: %d," > - " new lsn %d", (*row)->replica_id, > - vclock_get(base, (*row)->replica_id) + > - vclock_get(vclock_diff, > - (*row)->replica_id), > - (*row)->lsn); > + " replica id: %d, confirmed lsn: %lld," Replica ID should be %u, it is unsigned. > + " new lsn %lld", (*row)->replica_id, > + (long long)confirmed_lsn, > + (long long)(*row)->lsn);