温度 = p_long; 显示内存泄漏。我不确定它是如何内存泄漏的。
long *temp = NULL; 
for (int i = 1; i < 10; i++) {
  if (i < 3) {
     long *p_long = new long;
     if ( p_long ) {
        if ( 0 == *p_long ) {
           flag = true;
        } else if ( 1 == *p_long ) {
           temp = p_long;                    -----> showing memory leak here
           continue;
        }
     }
  }
}
if (temp)
delete temp;
谢谢。