2014-05-16 18:03 GMT+02:00 J.R. Oldroyd <f...@opal.com>:
> sysutils/xfce4-wavelan-plugin no longer works.
>
> Looking at the code, there are various problems.  It looks for a sysctl
> oid that doesn't exist, it returns the interface rssi value instead of
> properly calculating the signal quality, it uses that incorrect rssi
> value also as the signal percentage, but worse... all the FreeBSD code
> is compiled out anyway due to tests for FreeBSD_version being done before
> sys/param.h is included!!
>
> I've posted two patches (URLs below) that fix these problems and make it
> work again.  I also fix the percentage values at which the color changes,
> I use 25%, 50% and 75% instead of the strange values 40%, 55% and 70% that
> are there now.
>
> I've named these files extra-patch-foo for now, but they should be renamed
> to patch-foo and merged in with the existing patches already there.
>
> The code in wi_bsd.c is a mess!  There is no need to be using the kernel
> values __FreeBSD_kernel__ or __FreeBSD_kernel_version here or even
> __FreeBSD_kernel_kernel__ (yes, really)!  I didn't clean that stuff up
> with this patch, but if desired, I can do so.  Maybe there's a reason
> it's like this?
>
>         -jr
>
> http://opal.com/jr/freebsd/ports/sysutils/xfce4-wavelan-plugin/extra-patch-panel-plugin__wavelan.c
> http://opal.com/jr/freebsd/ports/sysutils/xfce4-wavelan-plugin/extra-patch-panel-plugin__wi_bsd.c

Thanks you for your help.
When I upgraded this plugin, I removed some old code too [1], but
development seems to stop.

As I don't use this plugin, so I didn't notice odd behaviour of percentage.

Check of kernel version is used for Debian GNU/kFreeBSD port (I know
it's overkill).

[1] https://bugzilla.xfce.org/show_bug.cgi?id=8833

-- 
olivier
_______________________________________________
freebsd-xfce@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-xfce
To unsubscribe, send any mail to "freebsd-xfce-unsubscr...@freebsd.org"

Reply via email to