1
0

lpsend.rc 361 B

123456789101112131415161718
  1. #!/bin/rc
  2. if (! ~ $DEBUG '') { flag x + }
  3. if (test -e /net/tcp/clone) {
  4. dialstring=`{ndb/query sys $1 dom}
  5. network=tcp
  6. if (~ $#dialstring 0 || ! ~ $dialstring '') {
  7. dialstring=$1
  8. }
  9. if(lpsend $network^!^$dialstring^!printer) exit ''
  10. rv='tcp failed'
  11. }
  12. if not rv='no tcp'
  13. if (! ~ $dialstring '')
  14. exit 'lpsend: no dialstring'
  15. if not
  16. exit 'lpsend: '^$rv