[Kst] kst_hfi_calib_branch: kdeextragear-2/kst/kst

Barth Netterfield netterfield at astro.utoronto.ca
Tue Nov 9 22:37:32 CET 2004


OK.


On November 9, 2004 10:31 am, George Staikos wrote:
> CVS commit by staikos:
>
> fix a major deadlock issue with the reload action.  This needs a backport.
> Can someone please review it?  Thanks.
>
>
>   M +5 -3      kstrvector.cpp   1.64.2.1
>
>
> --- kdeextragear-2/kst/kst/kstrvector.cpp  #1.64:1.64.2.1
> @@ -17,4 +17,5 @@
>  
> ***************************************************************************
>/
>
> +#include <assert.h>
>  #include <math.h>
>  #include <stdlib.h>
> @@ -595,12 +596,13 @@ void KstRVector::reload() {
>        //
>        KstDataSourcePtr newsrc =
> KstDataSource::loadSource(_file->fileName(), _file->fileType()); -     
> _file->writeUnlock();
> +      assert(newsrc != _file);
>        if (newsrc) {
> +        _file->writeUnlock();
>          KST::dataSourceList.lock().writeLock();
>          KST::dataSourceList.remove(_file);
> -        KST::dataSourceList.append(newsrc);
> -        KST::dataSourceList.lock().writeUnlock();
>          _file = newsrc;
>          _file->writeLock();
> +        KST::dataSourceList.append(_file);
> +        KST::dataSourceList.lock().writeUnlock();
>          reset();
>        }
>
>
> _______________________________________________
> Kst mailing list
> Kst at kde.org
> https://mail.kde.org/mailman/listinfo/kst



More information about the Kst mailing list