codesearch.isocpp.org by Andrew Tomazos.

Enter a valid C/C++ code snippet...

Searching for `static_cast<size_t>`...

2489599 source files searched.

27515 matches found.

Here is a random sample of matches...


actcd19/main/libr/libreoffice/libreoffice_6.1.5-1/sw/source/filter/ww8/wrtw8sty.cxx:1847:

    void WW8_WrPlcSepx::WritePlcSed( WW8Export& rWrt ) const
{
OSL_ENSURE(m_SectionAttributes.size() == static_cast<size_t>(aSects.size())
, "WritePlcSed(): arrays out of sync!");
OSL_ENSURE( aCps.size() == aSects.size() + 1, "WrPlcSepx: DeSync" );


actcd19/main/f/firefox-esr/firefox-esr_60.5.1esr-1/gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Context11.cpp:243:

    void Context11::insertEventMarker(GLsizei length, const char *marker)
{
auto optionalString = angle::WidenString(static_cast<size_t>(length), marker);
if (optionalString.valid())
{


actcd19/main/t/texmaker/texmaker_5.0.3-1/pdfium/fpdfsdk/fpdftext_embeddertest.cpp:52:

      // Count does not include the terminating NUL in the string literal.
EXPECT_EQ(sizeof(expected) - 1,
static_cast<size_t>(FPDFText_CountChars(textpage)));
for (size_t i = 0; i < sizeof(expected) - 1; ++i) {
EXPECT_EQ(static_cast<unsigned int>(expected[i]),


actcd19/main/l/llvm-toolchain-8/llvm-toolchain-8_8~+rc3-1~exp1/libcxx/test/std/re/re.alg/re.alg.search/awk.pass.cpp:670:

            assert(m.suffix().first == m[0].second);
assert(m.suffix().second == m[0].second);
assert(m.length(0) >= 0 && static_cast<size_t>(m.length(0)) == std::char_traits<char>::length(s));
assert(m.position(0) == 0);
assert(m.str(0) == s);


actcd19/main/c/chromium/chromium_72.0.3626.121-1/net/filter/filter_source_stream_unittest.cc:423:

          break;
ASSERT_GT(rv, OK);
ASSERT_GE(kSmallBufferSize, static_cast<size_t>(rv));
actual_output.append(output_buffer->data(), rv);
}


actcd19/main/f/firefox-esr/firefox-esr_60.5.1esr-1/gfx/angle/checkout/src/libANGLE/State.cpp:2161:

        {
case GL_TRANSFORM_FEEDBACK_BUFFER_START:
ASSERT(static_cast<size_t>(index) < mTransformFeedback->getIndexedBufferCount());
*data = mTransformFeedback->getIndexedBuffer(index).getOffset();
break;


actcd19/main/c/chromium/chromium_72.0.3626.121-1/media/base/audio_shifter_unittest.cc:87:

            bool silence = true;
for (size_t j = 0;
j < static_cast<size_t>(test_output_->frames());
j++) {
if (test_output_->channel(0)[j] != 0.0) {


actcd19/main/q/qtwebengine-opensource-src/qtwebengine-opensource-src_5.11.3+dfsg-2/src/3rdparty/chromium/media/audio/audio_low_latency_input_output_unittest.cc:208:

          EXPECT_EQ(channels_, dest->channels());
size = std::min(dest->frames() * frame_size_, size);
EXPECT_EQ(static_cast<size_t>(size) % sizeof(*dest->channel(0)), 0U);
dest->FromInterleaved(source, size / frame_size_,
frame_size_ / channels_);


actcd19/main/f/flare-engine/flare-engine_1.09.01-1/src/EventManager.cpp:757:

    			}
else {
size_t index = static_cast<size_t>(distance(mapr->layernames.begin(), find(mapr->layernames.begin(), mapr->layernames.end(), ec->s)));
if (!mapr->isValidTile(ec->z))
Utils::logError("EventManager: Mapmod at position (%d, %d) contains invalid tile id (%d).", ec->x, ec->y, ec->z);


actcd19/main/k/kicad/kicad_5.0.2+dfsg1-1/qa/polygon_triangulation/test_polygon_triangulation.cpp:242:

            {
for( size_t areaId = zonesToTriangulate.fetch_add( 1 );
areaId < static_cast<size_t>( brd->GetAreaCount() );
areaId = zonesToTriangulate.fetch_add( 1 ) )
{


actcd19/main/c/cataclysm-dda/cataclysm-dda_0.C+git20190228.faafa3a-2/src/crafting.cpp:929:

    
if( cmenu.ret < 0 ||
static_cast<size_t>( cmenu.ret ) >= map_has.size() + player_has.size() + mixed.size() ) {
selected.use_from = cancel;
return selected;


actcd19/main/o/opengm/opengm_2.3.6+20160905-1/src/unittest/test_accessor_iterator.cxx:189:

          std::vector<size_t> vec1(10);
for(size_t j=0; j<vec1.size(); ++j) {
vec1[j] = static_cast<size_t>(j);
}
VectorAccessor<size_t, false> accessor1(vec1);


actcd19/main/w/webkit2gtk/webkit2gtk_2.18.3-1/Tools/TestWebKitAPI/Tests/WTF/StringView.cpp:429:

        EXPECT_EQ(static_cast<size_t>(WTF::notFound), referenceB.findIgnoringASCIICase(stringViewFromLiteral("Y")));
EXPECT_EQ(static_cast<size_t>(WTF::notFound), referenceB.findIgnoringASCIICase(stringViewFromUTF8(tempStringHolder, "ABdÉ")));
EXPECT_EQ(static_cast<size_t>(WTF::notFound), referenceB.findIgnoringASCIICase(stringViewFromUTF8(tempStringHolder, "ABCé")));

// Find the infix.


actcd19/main/i/imagevis3d/imagevis3d_3.1.0-7/.pc/fixsparc.patch/Tuvok/IO/DynamicBrickingDS.cpp:315:

      assert(std::get<1>(tgtkey) < src.GetLODLevelCount());
const size_t lod = std::min(std::get<1>(tgtkey),
static_cast<size_t>(src.GetLODLevelCount()));
const size_t timestep = std::get<0>(tgtkey);
// identify how many voxels we've got


actcd19/main/a/android-platform-art/android-platform-art_8.1.0+r23-3/runtime/stack_map.h:1137:

    // A byte sized table of possible variable sized encodings.
struct ByteSizedTable {
static constexpr size_t kInvalidOffset = static_cast<size_t>(-1);

// Number of entries in the table (serialized).


actcd19/main/r/rocksdb/rocksdb_5.17.2-3/monitoring/histogram_windowing.cc:92:

        uint64_t other_window_index =
(other_cur_window + other.num_windows_ - i) % other.num_windows_;
size_t windex = static_cast<size_t>(window_index);
size_t other_windex = static_cast<size_t>(other_window_index);


actcd19/main/f/frobby/frobby_0.9.0-5/.pc/add_unistd.h.patch/src/randomDataGenerators.cpp:302:

    	size_t getAnchorLeft(size_t node) const {
ASSERT(node <= getNodeCount());
for (--node; node != static_cast<size_t>(-1); --node)
if (isAnchor(node))
break;


actcd19/main/w/webkit2gtk/webkit2gtk_2.18.3-1/Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:2571:

        }

if (m_cachedStatements[static_cast<size_t>(sql)]) {
if (m_cachedStatements[static_cast<size_t>(sql)]->reset() == SQLITE_OK)
return m_cachedStatements[static_cast<size_t>(sql)].get();


actcd19/main/t/thunderbird/thunderbird_60.5.1-1/modules/pdfium/pdfium/fpdfsdk/fpdftext_embeddertest.cpp:386:

    
int count = FPDFText_CountChars(textpage);
ASSERT_EQ(FX_ArraySize(kExpectedFontsSizes), static_cast<size_t>(count));
for (int i = 0; i < count; ++i)
EXPECT_EQ(kExpectedFontsSizes[i], FPDFText_GetFontSize(textpage, i)) << i;


actcd19/main/libr/libreoffice/libreoffice_6.1.5-1/sc/source/filter/excel/xeformula.cxx:198:

        {
// move pointer to next entry, if something explicit follows
if( (static_cast< size_t >( mpParamInfo - mrFuncInfo.mpParamInfos + 1 ) < EXC_FUNCINFO_PARAMINFO_COUNT) && (mpParamInfo[ 1 ].meValid != EXC_PARAM_NONE) )
++mpParamInfo;
// if last parameter type is 'Excel-only' or 'Calc-only', do not repeat it


actcd19/main/s/swift-im/swift-im_3.0.4-1/Swiften/Parser/PayloadParsers/UnitTest/JingleParserTest.cpp:159:

    			CPPUNIT_ASSERT_EQUAL(JingleContentPayload::InitiatorCreator, payload->getCreator());
CPPUNIT_ASSERT_EQUAL(std::string("ex"), payload->getName());
CPPUNIT_ASSERT_EQUAL(static_cast<size_t>(1), payload->getTransports().size());

JingleIBBTransportPayload::ref transportPaylod = payload->getTransport<JingleIBBTransportPayload>();


actcd19/main/g/gdal/gdal_2.4.0+dfsg-1/alg/gdalwarper.cpp:369:

        const double *padfNoData = static_cast<double*>(pMaskFuncArg);
GUInt32 *panValidityMask = static_cast<GUInt32 *>(pValidityMask);
const size_t nPixels = static_cast<size_t>(nXSize) * nYSize;

*pbOutAllValid = FALSE;


actcd19/main/c/codequery/codequery_0.21.0+dfsg1-1/scintilla/src/Document.cxx:1918:

    					folded[lenFlat] = 0;
// memcmp may examine lenFlat bytes in both arguments so assert it doesn't read past end of searchThing
assert(static_cast<size_t>(indexSearch + lenFlat) <= searchThing.size());
// Does folded match the buffer
characterMatches = 0 == memcmp(folded, &searchThing[0] + indexSearch, lenFlat);


actcd19/main/libk/libkml/libkml_1.3.0-5/tests/kml/dom/geometry_test.cc:59:

    // Verify proper defaults:
TEST_F(CoordinatesTest, TestDefaults) {
ASSERT_EQ(static_cast<size_t>(0), coordinates_->get_coordinates_array_size());
}


actcd19/main/m/mosh/mosh_1.2.6-1/src/network/network.cc:386:

      hints.ai_flags = AI_NUMERICHOST | AI_NUMERICSERV;
AddrInfo ai( ip, port, &hints );
fatal_assert( static_cast<size_t>( ai.res->ai_addrlen ) <= sizeof( remote_addr ) );
remote_addr_len = ai.res->ai_addrlen;
memcpy( &remote_addr.sa, ai.res->ai_addr, remote_addr_len );


actcd19/main/p/paraview/paraview_5.4.1+dfsg4-3.1/VTK/Common/Core/vtkByteSwap.cxx:134:

      // No need to swap segments of 1 byte.
os->write(reinterpret_cast<const char*>(first),
num*static_cast<size_t>(sizeof(unsigned char)));
}
template <class T>


actcd19/main/c/ccfits/ccfits_2.5+dfsg-1/ColumnVectorData.cxx:144:

                const size_t ONE = 1;

if (m_data.size() != static_cast<size_t>(rows())) m_data.resize(rows());
size_t vectorSize(0);
if (!varLength())


actcd19/main/c/chromium/chromium_72.0.3626.121-1/third_party/leveldatabase/src/db/log_reader.cc:190:

      if (reporter_ != nullptr &&
end_of_buffer_offset_ - buffer_.size() - bytes >= initial_offset_) {
reporter_->Corruption(static_cast<size_t>(bytes), reason);
}
}


actcd19/main/c/chromium/chromium_72.0.3626.121-1/chrome/browser/custom_handlers/protocol_handler_registry_unittest.cc:708:

      std::vector<std::string> handled_protocols;
registry()->GetRegisteredProtocols(&handled_protocols);
ASSERT_EQ(static_cast<size_t>(1), handled_protocols.size());
ASSERT_EQ("test", handled_protocols[0]);
}


actcd19/main/m/mongodb/mongodb_3.4.18-2/src/third_party/mozjs-45/extract/mfbt/double-conversion/utils.h:222:

      void AddSubstring(const char* s, int n) {
ASSERT(!is_finalized() && position_ + n < buffer_.length());
ASSERT(static_cast<size_t>(n) <= strlen(s));
memmove(&buffer_[position_], s, n * kCharSize);
position_ += n;


actcd19/main/e/eclipse-titan/eclipse-titan_6.5.0-1/core/BER.cc:35:

    /** A \c size_t value with 8 bits set (0xFF) in the most significant byte */
static const size_t size_t_8msb
=static_cast<size_t>(0xFF)<<(sizeof(size_t)*8-8);

const unsigned long long unsigned_llong_7msb


actcd19/main/c/chromium/chromium_72.0.3626.121-1/base/security_unittest.cc:122:

      ptrdiff_t ptr_diff = reinterpret_cast<char*>(std::max(ptr1, ptr2)) -
reinterpret_cast<char*>(std::min(ptr1, ptr2));
return static_cast<size_t>(ptr_diff) <= size;
}


actcd19/main/libk/libkml/libkml_1.3.0-5/tests/kml/convenience/element_counter_test.cc:79:

      ElementPtr root = parser_->Parse(kKml, NULL);
ASSERT_TRUE(root);
ASSERT_EQ(static_cast<size_t>(2), element_count_map_.size());
ASSERT_EQ(1, element_count_map_[kmldom::Type_Folder]);
ASSERT_EQ(2, element_count_map_[kmldom::Type_Placemark]);


actcd19/main/w/webkit2gtk/webkit2gtk_2.22.7-1/Source/JavaScriptCore/bytecode/CodeBlock.h:909:

        void replaceConstant(int index, JSValue value)
{
ASSERT(isConstantRegisterIndex(index) && static_cast<size_t>(index - FirstConstantRegisterIndex) < m_constantRegisters.size());
m_constantRegisters[index - FirstConstantRegisterIndex].set(*m_poisonedVM, this, value);
}


actcd19/main/k/kodi/kodi_17.6+dfsg1-4/xbmc/guilib/XBTFReader.cpp:224:

        return false;

if (fread(buffer, 1, static_cast<size_t>(frame.GetPackedSize()), m_file) != frame.GetPackedSize())
return false;


actcd19/main/o/openjdk-12/openjdk-12_12~33-1/src/hotspot/share/gc/g1/g1ConcurrentRefine.cpp:332:

      if (update_rs_time > goal_ms) {
if (green > 0) {
green = static_cast<size_t>(green * dec_k);
}
} else if (update_rs_time < goal_ms &&


actcd19/main/f/firefox/firefox_65.0.1-1/media/webrtc/trunk/webrtc/rtc_base/stringutils.h:210:

                     va_list args) {
int len = vsnprintf(buffer, buflen, format, args);
if ((len < 0) || (static_cast<size_t>(len) >= buflen)) {
len = static_cast<int>(buflen - 1);
buffer[len] = 0;


actcd19/main/p/pcl/pcl_1.9.1+dfsg1-3/ml/include/pcl/ml/multi_channel_2d_comparison_feature_handler.h:288:

          const size_t p1_row = static_cast<size_t> (scale * feature.p1.y + center_row_index);

const size_t p2_col = static_cast<size_t> (scale * feature.p2.x + center_col_index);
const size_t p2_row = static_cast<size_t> (scale * feature.p2.y + center_row_index);


actcd19/main/c/chromium/chromium_72.0.3626.121-1/base/memory/shared_memory_win.cc:305:

      }

if (bytes > static_cast<size_t>(std::numeric_limits<int>::max())) {
DLOG(ERROR) << "Bytes required exceeds the 2G limitation.";
return false;


actcd19/main/a/android-platform-art/android-platform-art_8.1.0+r23-3/runtime/native/sun_misc_Unsafe.cc:71:

        mirror::HeapReference<mirror::Object>* field_addr =
reinterpret_cast<mirror::HeapReference<mirror::Object>*>(
reinterpret_cast<uint8_t*>(obj.Ptr()) + static_cast<size_t>(offset));
ReadBarrier::Barrier<mirror::Object, kWithReadBarrier, /* kAlwaysUpdateField */ true>(
obj.Ptr(),


actcd19/main/libt/libt3widget/libt3widget_1.0.3-1/src/widgets/filepane.cc:186:

        case EKEY_PGUP:
height = window.get_height() - 1;
if (impl->current < static_cast<size_t>(2) * height) {
impl->current = 0;
} else {


actcd19/main/n/nodejs/nodejs_10.15.2~dfsg-1/src/node_crypto.cc:153:

    static int PasswordCallback(char* buf, int size, int rwflag, void* u) {
if (u) {
size_t buflen = static_cast<size_t>(size);
size_t len = strlen(static_cast<const char*>(u));
len = len > buflen ? buflen : len;


actcd19/main/c/chromium/chromium_72.0.3626.121-1/net/base/ip_endpoint_unittest.cc:30:

                                             socklen_t address_len) {
if (address->sa_family == AF_INET) {
DCHECK_LE(sizeof(sockaddr_in), static_cast<size_t>(address_len));
const struct sockaddr_in* sockaddr =
reinterpret_cast<const struct sockaddr_in*>(address);


actcd19/main/n/nodejs/nodejs_4.6.1~dfsg-1/deps/v8/src/compiler/common-operator.h:43:

    }

inline size_t hash_value(BranchHint hint) { return static_cast<size_t>(hint); }

std::ostream& operator<<(std::ostream&, BranchHint);


actcd19/main/c/chromium/chromium_72.0.3626.121-1/media/cdm/aes_decryptor.cc:313:

      for (auto it = keys.begin(); it != keys.end(); ++it) {
if (it->second.length() !=
static_cast<size_t>(DecryptConfig::kDecryptionKeySize)) {
DVLOG(1) << "Invalid key length: " << it->second.length();
*exception = CdmPromise::Exception::TYPE_ERROR;


actcd19/main/a/android-platform-art/android-platform-art_8.1.0+r23-3/compiler/jni/quick/arm/calling_convention_arm.cc:386:

    size_t ArmJniCallingConvention::FrameSize() {
// Method*, LR and callee save area size, local reference segment state
const size_t method_ptr_size = static_cast<size_t>(kArmPointerSize);
const size_t lr_return_addr_size = kFramePointerSize;
const size_t callee_save_area_size = CalleeSaveRegisters().size() * kFramePointerSize;


actcd19/main/f/firefox-esr/firefox-esr_60.5.1esr-1/gfx/skia/skia/src/gpu/vk/GrVkGpu.cpp:1168:

                for (int i = 0; i < h; ++i) {
memset(mapPtr, 0, srcRowBytes);
mapPtr = SkTAddOffset<void>(mapPtr, static_cast<size_t>(dstRowBytes));
}
}


actcd19/main/libr/libreoffice/libreoffice_5.4.3-4/sc/source/filter/xml/XMLStylesExportHelper.cxx:846:

        bool& bIsAutoStyle, sal_Int32& nValidationIndex, sal_Int32& nNumberFormat, const sal_Int32 nRemoveBeforeRow)
{
OSL_ENSURE(static_cast<size_t>(nTable) < aTables.size(), "wrong table");
if (!(static_cast<size_t>(nTable) < aTables.size()))
return -1;


actcd19/main/g/gromacs/gromacs_2019-2/src/gromacs/gmxana/sfactor.cpp:408:

            for (i = 0; i < cnt; i++)
{
if (std::strlen(gsft->atomnm[tndx[i]]) > static_cast<size_t>(nrc))
{
nrc = std::strlen(gsft->atomnm[tndx[i]]);


actcd19/main/m/mysql-5.7/mysql-5.7_5.7.25-1/sql/sql_parse.cc:1507:

    #endif

size_t length= static_cast<size_t>(packet_end - beginning_of_next_stmt);

log_slow_statement(thd);


actcd19/main/libr/libreoffice/libreoffice_6.0.5-1/sc/source/core/data/dpoutput.cxx:1594:

        //  test for row header

if ( nRow+1 == nDataStartRow && nCol >= nTabStartCol && static_cast<size_t>(nCol) < nTabStartCol + pRowFields.size() )
{
rOrient = sheet::DataPilotFieldOrientation_ROW;


actcd19/main/j/jellyfish1/jellyfish1_1.1.11-4/unit_tests/gtest/src/gtest-port.cc:306:

      const size_t min_count = (repeat == '+') ? 1 : 0;
const size_t max_count = (repeat == '?') ? 1 :
static_cast<size_t>(-1) - 1;
// We cannot call numeric_limits::max() as it conflicts with the
// max() macro on Windows.


actcd19/main/q/qtwebkit/qtwebkit_2.3.4.dfsg-10/Tools/DumpRenderTree/blackberry/TestRunnerBlackBerry.cpp:731:

            if (!JSValueIsNumber(context, lengthValue))
return false;
length = static_cast<size_t>(JSValueToNumber(context, lengthValue, 0));
}


actcd19/main/q/qtwebengine-opensource-src/qtwebengine-opensource-src_5.11.3+dfsg-2/src/3rdparty/chromium/content/renderer/android/disambiguation_popup_helper_unittest.cc:73:

    TEST_F(DisambiguationPopupHelperUnittest, LongLinks) {
gfx::Rect tap_rect(10, 10, 20, 20);
blink::WebVector<blink::WebRect> target_rects(static_cast<size_t>(2));
target_rects[0] = gfx::Rect(15, 15, 1000, 5);
target_rects[1] = gfx::Rect(15, 25, 1000, 5);


actcd19/main/libr/libreoffice/libreoffice_6.1.5-1/extensions/source/ole/unoobjw.cxx:795:

                return ret;

if ((dispidMember > 0) && (static_cast<size_t>(dispidMember) <= m_MemberInfos.size()) && m_xInvocation.is())
{
MemberInfo d = m_MemberInfos[dispidMember - 1];


actcd19/main/g/gcc-arm-none-eabi/gcc-arm-none-eabi_7-2018-q2-6/libstdc++-v3/include/bits/random.h:71:

    
template<typename _UIntType, size_t __w,
bool = __w < static_cast<size_t>
(std::numeric_limits<_UIntType>::digits)>
struct _Shift


actcd19/main/m/marisa/marisa_0.2.5-2/bindings/ruby/marisa-swig_wrap.cxx:2713:

        }
}
vresult = SWIG_From_size_t(static_cast< size_t >(result));
return vresult;
fail:


actcd19/main/o/opengm/opengm_2.3.6+20160905-1/src/interfaces/python/opengm/inference/lp_def_suite.hxx:85:

       ) {

const size_t nVi = static_cast<size_t>(lpVariableIndices.shape(0));
const size_t nCoeff = static_cast<size_t>(coefficients.shape(0));
const size_t nLBound = static_cast<size_t>(lowerBounds.size());


actcd19/main/s/swift-im/swift-im_2.0+dev6-1/Swiften/StreamStack/UnitTest/StreamStackTest.cpp:68:

    			xmppStream_->writeData("foo");

CPPUNIT_ASSERT_EQUAL(static_cast<size_t>(1), physicalStream_->data_.size());
CPPUNIT_ASSERT_EQUAL(createSafeByteArray("Xfoo"), physicalStream_->data_[0]);
}


actcd19/main/b/bedops/bedops_2.4.35+dfsg-1/.pc/use_debian_libs/applications/bed/starch/src/starchcat.c:1763:

    #ifdef __cplusplus
if (nRetransformBuf + nRetransformLineBufPos < static_cast<int64_t>( sizeof(retransformBuf) )) {
memcpy(retransformBuf + nRetransformBuf, retransformLineBuf, static_cast<size_t>( nRetransformLineBufPos ));
#else
if (nRetransformBuf + nRetransformLineBufPos < (int64_t) sizeof(retransformBuf)) {


actcd19/main/c/chromium/chromium_72.0.3626.121-1/cc/base/list_container_helper.cc:390:

    
ListContainerHelper::ReverseIterator ListContainerHelper::rend() {
return ReverseIterator(data_.get(), static_cast<size_t>(-1), nullptr, size());
}


actcd19/main/c/chromium/chromium_72.0.3626.121-1/cc/paint/paint_op_writer.cc:292:

    void PaintOpWriter::Write(const SkColorSpace* color_space) {
if (!color_space) {
WriteSize(static_cast<size_t>(0));
return;
}


actcd19/main/p/protobuf/protobuf_3.0.0-7/src/google/protobuf/repeated_field.h:1264:

      new_size = std::max(google::protobuf::internal::kMinRepeatedFieldAllocationSize,
std::max(total_size_ * 2, new_size));
GOOGLE_CHECK_LE(static_cast<size_t>(new_size),
(std::numeric_limits<size_t>::max() - kRepHeaderSize) /
sizeof(Element))


actcd19/main/q/qtwebengine-opensource-src/qtwebengine-opensource-src_5.11.3+dfsg-2/src/3rdparty/chromium/v8/src/factory.cc:2302:

      CHECK(number_of_elements <=
(std::numeric_limits<size_t>::max() / element_size));
CHECK(number_of_elements <= static_cast<size_t>(Smi::kMaxValue));
size_t byte_length = number_of_elements * element_size;


actcd19/main/v/vtk6/vtk6_6.3.0+dfsg2-2/Rendering/Label/vtkLabelHierarchy.cxx:2298:

      int tdm = ( 1 << d ) - 1; // 2^d - 1
double n = static_cast<double>(t)*(tdl-1.)/tdl/static_cast<double>(tdm);
size_t nr = static_cast<size_t>(floor( n )); // truncate...
double rem = n - nr;
if ( rem > 0. )


actcd19/main/c/chromium/chromium_72.0.3626.121-1/base/strings/safe_sprintf.cc:143:

      // maximum possible value.
inline bool OutOfAddressableSpace() const {
return count_ == static_cast<size_t>(kSSizeMax - 1);
}


actcd19/main/libr/libreoffice/libreoffice_6.0.6~rc1-1/sc/source/filter/xml/XMLStylesExportHelper.cxx:796:

            {
i = 0;
while (!bFound && static_cast<size_t>(i) < aAutoStyleNames.size())
{
if (*aAutoStyleNames[i] == rString)


actcd19/main/r/rocksdb/rocksdb_5.17.2-3/utilities/document/document_db.cc:1161:

      rocksdb_options.max_write_buffer_number = 6;
BlockBasedTableOptions table_options;
table_options.block_cache = NewLRUCache(static_cast<size_t>(options.cache_size));
rocksdb_options.table_factory.reset(NewBlockBasedTableFactory(table_options));
return rocksdb_options;


actcd19/main/l/llvm-toolchain-6.0/llvm-toolchain-6.0_6.0.1-10/lldb/source/Core/IOHandler.cpp:4334:

          if (m_selected_line > 0) {
m_selected_line--;
if (static_cast<size_t>(m_first_visible_line) > m_selected_line)
m_first_visible_line = m_selected_line;
}


actcd19/main/k/kde4libs/kde4libs_4.14.38-3/kjs/function.cpp:673:

    #endif
size_t numParams = body->numParams();
size_t numPassedIn = min(numParams, static_cast<size_t>(arguments->size()));

size_t pos = 0;


actcd19/main/n/nss-pem/nss-pem_1.0.4-1/nss/nss/gtests/ssl_gtest/tls_connect.cc:841:

      uint32_t tmp = 0;
EXPECT_TRUE(ext.Read(0, 2, &tmp));
EXPECT_EQ(ext.len() - 2, static_cast<size_t>(tmp));
EXPECT_TRUE(ext.len() % 2 == 0);


actcd19/main/l/llvm-toolchain-8/llvm-toolchain-8_8~+rc3-1~exp1/libcxx/test/std/re/re.alg/re.alg.search/ecma.pass.cpp:639:

            assert(m.suffix().first == m[0].second);
assert(m.suffix().second == m[0].second);
assert(m.length(0) >= 0 && static_cast<size_t>(m.length(0)) == std::char_traits<char>::length(s));
assert(m.position(0) == 0);
assert(m.str(0) == s);


actcd19/main/c/cppad/cppad_2019.02.00.1-1/include/cppad/core/vec_ad.hpp:645:

    
// index in vector for this element
size_t i = static_cast<size_t>( Integer(ind_) );
CPPAD_ASSERT_UNKNOWN( i < vec_->length_ );


actcd19/main/n/nodejs/nodejs_10.15.2~dfsg-1/deps/v8/src/compiler/machine-graph-verifier.cc:49:

          case IrOpcode::kInt32SubWithOverflow:
case IrOpcode::kInt32MulWithOverflow:
CHECK_LE(index, static_cast<size_t>(1));
return index == 0 ? MachineRepresentation::kWord32
: MachineRepresentation::kBit;


actcd19/main/c/chromium/chromium_72.0.3626.121-1/third_party/webrtc/modules/audio_coding/neteq/nack_tracker_unittest.cc:253:

    
NackTracker::NackList nack_list = nack->GetNackList();
EXPECT_EQ(static_cast<size_t>(kNumAllLostPackets), nack_list.size());

// Pretend the first packet is decoded.


actcd19/main/r/rocksdb/rocksdb_5.17.2-3/utilities/persistent_cache/persistent_cache_test.cc:194:

          cache_ = std::make_shared<VolatileCacheTier>(
/*compressed=*/true, /*size=*/static_cast<size_t>(1 * 1024 * 1024 * kStressFactor));
RunInsertTestWithEviction(nthreads, static_cast<size_t>(max_keys));
}
}


actcd19/main/c/chromium/chromium_72.0.3626.121-1/third_party/webrtc/modules/video_coding/session_info_unittest.cc:346:

      FillPacket(1);
EXPECT_EQ(packet_buffer_size(),
static_cast<size_t>(session_.InsertPacket(packet_, frame_buffer_,
kNoErrors, frame_data)));
// Insert an older packet with a first packet set.


actcd19/main/o/opengm/opengm_2.3.6+20160905-1/include/opengm/datastructures/partition.hxx:160:

       }
else if(ranks_[static_cast<size_t>(element1)] > ranks_[static_cast<size_t>(element2)]) {
parents_[static_cast<size_t>(element2)] = element1;
--numberOfSets_;
}


actcd19/main/q/qtwebengine-opensource-src/qtwebengine-opensource-src_5.11.3+dfsg-2/src/3rdparty/chromium/third_party/libwebm/source/mkvmuxer/mkvmuxer.cc:1389:

      private_data_ = new_private_data;
private_data_length_ = data_length;
memcpy(private_data_, data, static_cast<size_t>(data_length));

return true;


actcd19/main/g/gcc-arm-none-eabi/gcc-arm-none-eabi_7-2018-q2-6/libstdc++-v3/testsuite/27_io/basic_filebuf/underflow/wchar_t/9178.cc:49:

      {
size_t len = std::min(static_cast<size_t>(from_end - from),
static_cast<size_t>(to_end - to) / width);

while (len--)


actcd19/main/s/sdcv/sdcv_0.5.2-2/.pc/0f83f0aa0b8340f2d59bb3a4e174585780a2c54b.patch/src/stardict_lib.cpp:540:

        guint32 page_size = wordoffset[page_idx + 1] - wordoffset[page_idx];
const size_t nitems = fread(wordentry_buf,
std::min(sizeof(wordentry_buf), static_cast<size_t>(page_size)),
1, idxfile);
THROW_IF_ERROR(nitems == 1);


actcd19/main/libk/libkml/libkml_1.3.0-5/tests/kml/regionator/regionator_test.cc:166:

      // and 64 great-grand-children.  This is partly particular to
// PointRegionHandler as it always creates 4 children if it creates any.
ASSERT_EQ(static_cast<size_t>(85), kml_file_map_.size());
}


actcd19/main/c/chromium/chromium_72.0.3626.121-1/third_party/angle/src/libANGLE/renderer/vulkan/vk_helpers.cpp:109:

        mAlignment = std::max(
alignment,
static_cast<size_t>(renderer->getPhysicalDeviceProperties().limits.nonCoherentAtomSize));
}


actcd19/main/f/firefox-esr/firefox-esr_60.5.1esr-1/media/webrtc/trunk/webrtc/modules/audio_coding/acm2/audio_coding_module.cc:690:

    
// If the length and frequency matches. We currently just support raw PCM.
if (static_cast<size_t>(audio_frame.sample_rate_hz_ / 100) !=
audio_frame.samples_per_channel_) {
WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceAudioCoding, id_,


actcd19/main/w/wsjtx/wsjtx_2.0.0+repack-2/boost/boost/multiprecision/cpp_dec_float.hpp:1749:

    
// Clear out the decimal portion
const size_t first_clear = (static_cast<size_t>(x.exp) / static_cast<size_t>(cpp_dec_float_elem_digits10)) + 1u;
const size_t last_clear = static_cast<size_t>(cpp_dec_float_elem_number);


actcd19/main/g/golang-github-google-certificate-transparency/golang-github-google-certificate-transparency_0.0~git20160709.0.0f6e3d1~ds1-3/cpp/util/etcd_test.cc:334:

      ASSERT_OK(task);
EXPECT_TRUE(resp.node.is_dir_);
ASSERT_EQ(static_cast<size_t>(2), resp.node.nodes_.size());
EXPECT_EQ(9, resp.node.nodes_[0].modified_index_);
EXPECT_EQ("123", resp.node.nodes_[0].value_);


actcd19/main/f/firefox/firefox_65.0.1-1/js/src/frontend/BinToken.cpp:43:

    
const BinaryASTSupport::CharSlice& getBinKind(const BinKind& variant) {
return BINKIND_DESCRIPTIONS[static_cast<size_t>(variant)];
}


actcd19/main/a/android-platform-art/android-platform-art_8.1.0+r23-3/compiler/optimizing/nodes.h:4375:

      static constexpr size_t kFieldClinitCheckRequirement = kNumberOfInvokePackedBits;
static constexpr size_t kFieldClinitCheckRequirementSize =
MinimumBitsToStore(static_cast<size_t>(ClinitCheckRequirement::kLast));
static constexpr size_t kNumberOfInvokeStaticOrDirectPackedBits =
kFieldClinitCheckRequirement + kFieldClinitCheckRequirementSize;


actcd19/main/q/qt3d-opensource-src/qt3d-opensource-src_5.10.1+dfsg-5/src/3rdparty/assimp/code/STEPFileEncoding.cpp:320:

                    }

const size_t outcount = static_cast<size_t>(tempp-temp);

s.erase(i,5);


actcd19/main/q/qtwebengine-opensource-src/qtwebengine-opensource-src_5.11.3+dfsg-2/src/3rdparty/chromium/base/strings/string_piece.cc:137:

          std::find(self.begin() + pos, self.end(), c);
return result != self.end() ?
static_cast<size_t>(result - self.begin()) : BasicStringPiece<STR>::npos;
}


actcd19/main/libr/libreoffice/libreoffice_6.1.5-1/include/unotools/compatibility.hxx:146:

            void setValue( const Index rIdx, T rValue )
{
if ( static_cast<size_t>(rIdx) < getElementCount() )
{
m_aPropertyValue[ static_cast<int>(rIdx) ] = css::uno::Any(rValue);


actcd19/main/p/passwordsafe/passwordsafe_1.06+dfsg-1/src/core/CoreImpExp.cpp:1287:

          if (!ci_temp.SetXTime(tokens[i_Offset[XTIME]].c_str()))
ReportInvalidField(rpt, vs_Header.at(XTIME), numlines);
if (i_Offset[XTIME_INT] >= 0 && tokens.size() > static_cast<size_t>(i_Offset[XTIME_INT]))
if (!ci_temp.SetXTimeInt(tokens[i_Offset[XTIME_INT]].c_str()))
ReportInvalidField(rpt, vs_Header.at(XTIME_INT), numlines);


actcd19/main/c/chromium/chromium_72.0.3626.121-1/media/gpu/vaapi/vaapi_wrapper.cc:793:

    
// Resize the list to the actual number of formats returned by the driver.
supported_formats_.resize(static_cast<size_t>(num_image_formats));
return true;
}


actcd19/main/libj/libjsoncpp/libjsoncpp_1.7.4-3/src/lib_json/json_reader.cpp:642:

    
bool Reader::decodeString(Token& token, JSONCPP_STRING& decoded) {
decoded.reserve(static_cast<size_t>(token.end_ - token.start_ - 2));
Location current = token.start_ + 1; // skip '"'
Location end = token.end_ - 1; // do not include '"'


actcd19/main/c/ceph/ceph_12.2.11+dfsg1-2/src/rocksdb/utilities/persistent_cache/persistent_cache_test.cc:263:

        const std::string& dbname) {
const auto memory_size = 1 * 1024 * 1024 * kStressFactor;
return NewTieredCache(Env::Default(), dbname, static_cast<size_t>(memory_size));
}


actcd19/main/g/gdal/gdal_2.4.0+dfsg-1/ogr/ogrsf_frmts/osm/ogrosmdatasource.cpp:708:

    bool OGROSMDataSource::FlushCurrentSectorNonCompressedCase()
{
if( VSIFWriteL(pabySector, 1, static_cast<size_t>(SECTOR_SIZE),
fpNodes) == static_cast<size_t>(SECTOR_SIZE) )
{


actcd19/main/r/rocksdb/rocksdb_5.17.2-3/db/compaction_picker.cc:1530:

          vstorage_->LevelFiles(0 /* level */);
if (level_files.size() <
static_cast<size_t>(
mutable_cf_options_.level0_file_num_compaction_trigger + 2) ||
level_files[0]->being_compacted) {


actcd19/main/p/percona-xtrabackup/percona-xtrabackup_2.2.3-2.1/sql/rpl_record.cc:154:

      DBUG_ASSERT(null_ptr == row_data + null_byte_count);
DBUG_DUMP("row_data", row_data, pack_ptr - row_data);
DBUG_RETURN(static_cast<size_t>(pack_ptr - row_data));
}
#endif


actcd19/main/p/paraview/paraview_5.4.1+dfsg4-3.1/ThirdParty/pugixml/pugixml.cxx:3753:

    			// read data to chunk
stream.read(chunk->data, static_cast<std::streamsize>(sizeof(chunk->data) / sizeof(T)));
chunk->size = static_cast<size_t>(stream.gcount()) * sizeof(T);

// read may set failbit | eofbit in case gcount() is less than read length, so check for other I/O errors


actcd19/main/v/valentina/valentina_0.6.1~dfsg-9/src/libs/vdxf/libdxfrw/libdxfrw.cpp:1232:

            int i;
for(i =0; (text.size()-static_cast<size_t>(i)) > 250; ) {
writer->writeString(3, text.substr(static_cast<size_t>(i), 250));
i +=250;
}