WebCore/ChangeLog
1
1
2010-01-05 Yong Li <yong.li@torchmobile.com>
2
2
3
Reviewed by NOBODY (OOPS!).
4
5
Fix build warnings blindly
6
https://bugs.webkit.org/show_bug.cgi?id=33178
7
8
* platform/SharedBuffer.cpp:
9
(WebCore::SharedBuffer::append):
10
11
2010-01-05 Yong Li <yong.li@torchmobile.com>
12
3
13
Reviewed by Darin Adler.
4
14
5
15
Fix an obvious bug and build errors in previous commit (r52795)
WebCore/platform/SharedBuffer.cpp
@
@
void SharedBuffer::append(const char* data, int length)
141
141
142
142
for (;;) {
143
143
memcpy(segment, data, bytesToCopy);
144
if (length == bytesToCopy)
144
if (
static_cast<unsigned>(
length
)
== bytesToCopy)
145
145
break;
146
146
147
length -= bytesToCopy;
147
length -=
static_cast<int>(
bytesToCopy
)
;
148
148
data += bytesToCopy;
149
149
segment = allocateSegment();
150
150
m_segments.append(segment);
151
bytesToCopy = length < segmentSize ? length : segmentSize;
151
bytesToCopy =
static_cast<unsigned>(
length
)
< segmentSize ?
static_cast<unsigned>(
length
)
: segmentSize;
152
152
}
153
153
}
154
154