소스 검색

Removed unneccessary safe_fixtable for ordered set

Via ets man page:
Note that for tables of the ordered_set type, safe_fixtable/2 is not
necessary as calls to first/1 and next/2 will always succeed
pull/123/head
benjaminplee 10 년 전
부모
커밋
5d11a7c649
1개의 변경된 파일1개의 추가작업 그리고 4개의 파일을 삭제
  1. +1
    -4
      src/ibrowse_lb.erl

+ 1
- 4
src/ibrowse_lb.erl 파일 보기

@ -224,10 +224,7 @@ code_change(_OldVsn, State, _Extra) ->
%%% Internal functions
%%--------------------------------------------------------------------
find_best_connection(Tid, Max_pipe) ->
ets:safe_fixtable(Tid, true),
Res = find_best_connection(ets:first(Tid), Tid, Max_pipe),
ets:safe_fixtable(Tid, false),
Res.
find_best_connection(ets:first(Tid), Tid, Max_pipe).
find_best_connection('$end_of_table', _, _) ->
{error, retry_later};

불러오는 중...
취소
저장