Changeset 5c7641 in git for Singular/ssiLink.cc


Ignore:
Timestamp:
Sep 23, 2010, 11:48:48 AM (14 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
fc2d16d75fa03d73ea81fee4ff230ad4158b821e
Parents:
952682018dfb5a9d68e53a49515369fa1838590d
Message:
better handling of ssiToBeClosed on ssi:fork

git-svn-id: file:///usr/local/Singular/svn/trunk@13255 2c84dea3-7e68-4137-9b89-c4e89433aadc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/ssiLink.cc

    r9526820 r5c7641  
    517517      if (pid==0) /*child*/
    518518      {
    519         link_list hh=ssiToBeClosed;
     519        link_list hh=(link_list)ssiToBeClosed->next;
     520        /* we know: l is the first entry in ssiToBeClosed-list */
    520521        while(hh!=NULL)
    521522        {
    522           if (hh->l!=l)
    523           {
    524             ssiInfo *dd=(ssiInfo*)hh->l->data;
    525             fclose(dd->f_read);
    526             fclose(dd->f_write);
    527             if (dd->r!=NULL) rKill(dd->r);
    528             omFreeSize((ADDRESS)dd,(sizeof *dd));
    529             hh->l->data=NULL;
    530             SI_LINK_SET_CLOSE_P(hh->l);
    531           }
    532           hh=(link_list)hh->next;
     523          ssiInfo *dd=(ssiInfo*)hh->l->data;
     524          fclose(dd->f_read);
     525          fclose(dd->f_write);
     526          if (dd->r!=NULL) rKill(dd->r);
     527          omFreeSize((ADDRESS)dd,(sizeof *dd));
     528          hh->l->data=NULL;
     529          SI_LINK_SET_CLOSE_P(hh->l);
     530          link_list nn=(link_list hh->next;
     531          omFree(hh);
     532          hh=nn;
    533533        }
     534        ssiToBeClosed->next=NULL;
    534535        close(pc[1]); close(cp[0]);
    535536        d->f_read=fdopen(pc[0],"r");
Note: See TracChangeset for help on using the changeset viewer.