Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 4c467ee in mainline


Ignore:
Timestamp:
2009-07-10T22:31:22Z (12 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master
Children:
ec8b0dac
Parents:
30f869d
Message:

In fibril_switch(), make sure to reload srcf with the current fibril address
in the post-context_restore() code. Its value may be invalid after
contex_restore() due to e.g. register recycling.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/libc/generic/fibril.c

    r30f869d r4c467ee  
    166166                /* Save current state */
    167167                if (!context_save(&srcf->ctx)) {
     168                        /*
     169                         * Make sure to reload srcf with the current fibril
     170                         * address. Its value may be invalid after
     171                         * contex_restore() due to e.g. register recycling.
     172                         */
     173                        srcf = __tcb_get()->fibril_data;
    168174                        if (serialization_count)
    169175                                srcf->flags &= ~FIBRIL_SERIALIZED;
Note: See TracChangeset for help on using the changeset viewer.