Enlightenment CVS committal

Author  : kwo
Project : e16
Module  : e

Dir     : e16/e/src


Modified Files:
        stacking.c 


Log Message:
Fix nastiness when there are more than 16 windows at startup.
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/stacking.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -3 -r1.12 -r1.13
--- stacking.c  28 Jun 2004 18:22:04 -0000      1.12
+++ stacking.c  30 Jul 2004 17:27:31 -0000      1.13
@@ -215,7 +215,7 @@
 EwinListGetForDesktop(int desk, int *num)
 {
    static EWin       **lst = NULL;
-   static int          nalloc;
+   static int          nalloc = 0;
    int                 i, n, nwins;
    EWin               *ewin;
 
@@ -223,7 +223,7 @@
    nwins = EwinListStack.nwins;
    if (nalloc < nwins)
      {
-       nalloc += 16;
+       nalloc = (nwins + 16) & ~0xf;   /* 16 at the time */
        lst = Erealloc(lst, nalloc * sizeof(EWin *));
      }
 




-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on
Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now,
one more big change to announce. We are now OSTG- Open Source Technology
Group. Come see the changes on the new OSTG site. www.ostg.com
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to