Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[9fans] devdraw.c

26 views
Skip to first unread message

Jeff Sickel

unread,
Oct 26, 2012, 2:10:48 PM10/26/12
to
I've been tracking down why the latest devdraw.c that includes winname just wasn't being read by rio in my drawterm-cocoa port. What I found is that /dev/winname is created during the #i initialization but subsequently never found in drawgen() after the qid has been created from Qtopdir. The following diff against the most recent Plan 9 sources versions of devdraw.c shows the change that lets drawterm resize the window and have rio pick up the change:

% diff /usr/local/src/plan9.bell-labs.com/plan9/sys/src/9/port/devdraw.c kern/devdraw.c
> drawgen(Chan *c, char *name, Dirtab *dt, int ndt, int s, Dir *dp)
218a219,222
> USED(name);
> USED(dt);
> USED(ndt);
>
254c258
< mkqid(&q, Qwinname, 0, 0);
---
> mkqid(&q, Qwinname, 0, QTFILE);
262a267,272
> if(t == Qwinname){
> mkqid(&q, Qwinname, 0, QTFILE);
> devdir(c, q, "winname", 0, eve, 0444, dp);
> return 1;
> }
>

These missing lines don't appear to be an issue in devvga.c or in the current 9vx.


Now that I've got clean resizing of a drawterm window working I'll be focused on cleaning up the rest of the diffs and pushing out a new version for OS X in the near term.

-jas

cinap_...@gmx.de

unread,
Oct 26, 2012, 4:20:36 PM10/26/12
to
yep. thats a bug. good catch!

--
cinap

0 new messages