Opened 13 years ago
Closed 13 years ago
#3755 closed defect (fixed)
PCIDSK CPL Mutex adapter creates mutex in acquired state
Reported by: | Even Rouault | Owned by: | Even Rouault |
---|---|---|---|
Priority: | normal | Milestone: | 1.7.3 |
Component: | default | Version: | 1.7.0 |
Severity: | normal | Keywords: | |
Cc: | warmerdam, jamesm@… |
Description
The following code blocks in GDALChecksumImage() when run on a .pix file.
#include <gdal.h> #include <gdal_alg.h> #include "cpl_multiproc.h" void my_thread(void* pData) { GDALDatasetH hDS; int checksum; hDS = (GDALDatasetH)pData; printf("in thread\n"); checksum = GDALChecksumImage(GDALGetRasterBand(hDS, 1), 0, 0, 20, 20); printf("checksum = %d\n", checksum); } int main(int argc, char* argv[]) { GDALDatasetH hDS; GDALAllRegister(); hDS = GDALOpen("byte.pix", GA_ReadOnly); CPLCreateThread(my_thread, hDS); CPLSleep(2); printf("finished\n"); return 0; }
This is due to an improper locking state at the creation of the CPLThreadMutex implementation of PCIDSK::Mutex
Change History (1)
comment:1 by , 13 years ago
Milestone: | → 1.7.3 |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Fixed in trunk (r20630) and in branches/1.7 (r20631)