Skip to content

Commit ea47230

Browse files
committed
updaate OS X library version
1 parent 0abd6a0 commit ea47230

4 files changed

Lines changed: 5 additions & 1 deletion

File tree

dist/stackimpact.jar

-34 Bytes
Binary file not shown.

examples/demo/DemoApp$1.class

0 Bytes
Binary file not shown.

examples/demo/DemoApp.class

-8 Bytes
Binary file not shown.

src/profile_recorder.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,11 @@ Frame* CreateFrame(jmethodID method, jint bci) {
7575

7676

7777
void ProfileRecorder::RecordSample(double measurement, void* context) {
78-
Sample* sample = &samples[sample_index++ % MAX_SAMPLES];
78+
if (sample_index + 1 > MAX_SAMPLES) {
79+
return;
80+
}
81+
82+
Sample* sample = &samples[sample_index++];
7983
sample->measurement = measurement;
8084

8185
AsyncGetCallTrace(&sample->call_trace, MAX_FRAMES, context);

0 commit comments

Comments
 (0)