ref: 28bd8adce7264b6f35016fca839391981b404428
parent: 595501b005f591527680080e606c9ab0f1d99701
author: cinap_lenrek <[email protected]>
date: Wed Mar 9 22:28:36 EST 2016
devcons: nil vs 0
--- a/sys/src/9/port/devcons.c
+++ b/sys/src/9/port/devcons.c
@@ -150,7 +150,7 @@
while(n > 0) {
t = memchr(str, '\n', n);
- if(t) {
+ if(t != nil) {
m = t-str;
if(usewrite){
qwrite(serialoq, str, m);
@@ -302,7 +302,7 @@
return 0;
c = up->fgrp->fd[2];
- if(c==0 || (c->mode!=OWRITE && c->mode!=ORDWR))
+ if(c==nil || (c->mode!=OWRITE && c->mode!=ORDWR))
return 0;
n = snprint(buf, sizeof buf, "%s %lud: ", up->text, up->pid);
va_start(arg, fmt);