스크립트 내에서 우선 순위를 변경하려고합니다. 성공하지 못했습니다. 자세한 내용은 여기를 참조하십시오.스레드 우선 순위 변경 ERROR_INVALID_HANDLE
$thr = threads->new(\&someFunction,
$shared variable 1,
$shared variable 2,
);
나는 threads::State
을 사용해 보았습니다. 성공없이
$thr->priority(2);
그래서 나는 성공없이 Win32::API
가 다시
my $functionGetLastError= Win32::API->new('Kernel32',
'GetLastError',
'',
'N'
);
my $functionSetThreadPriority= Win32::API->new('Kernel32',
'SetThreadPriority',
'II', # I've tried 'PI' and 'II' as well
'N'
);
my $h = $thr->_handle();
my $success = $functionSetThreadPriority->Call($h, 2);
warn "Return Error #".$functionGetLastError->Call() if !$success;
을 일해야한다 생각했다 : (하지만 지금은 단서, 스크립트 반환 오류 번호
이
MSDN site, System Error Codes (0-499)에서마지막 오류 6
, 오류가 내가 잘못 뭐하는 거지
ERROR_INVALID_HANDLE
것 같다?
참조 [펄 스레드입니다 스레드의 종류는?] (http://perldoc.perl.org/perlthrtut.html#What-kind-of-threads-are-Perl-threads%3f)에의 선적 서류 비치. – choroba