Page MenuHomeFreeBSD

morse: implement support for decoding morse code
ClosedPublic

Authored by eadler on Jan 4 2018, 1:29 AM.
Tags
None
Referenced Files
F87004801: D13757.id37580.diff
Fri, Jun 28, 6:11 AM
F87002199: D13757.diff
Fri, Jun 28, 5:50 AM
Unknown Object (File)
May 22 2024, 7:58 AM
Unknown Object (File)
May 22 2024, 4:30 AM
Unknown Object (File)
May 22 2024, 2:53 AM
Unknown Object (File)
May 22 2024, 2:29 AM
Unknown Object (File)
May 21 2024, 10:59 PM
Unknown Object (File)
May 21 2024, 10:32 PM

Details

Reviewers
kevans
Group Reviewers
manpages
Summary
  • Use -r for "reverse" mode and to match DragonFlyBSD.
  • Move defines around to clear up logic
  • use errx instead of fprintf and exit

PR: 35109
Submitted By: philipp.mergenthaler@stud.uni-karlsruhe.de
Submitted on: 2002-02-19

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 14131
Build 14304: arc lint + arc unit

Event Timeline

allanjude added inline comments.
usr.bin/morse/morse.c
351

A and B and C reads badly

try: "only one of -l, -s, and -D may be used"

I have some nits to be picked. =p Please don't hate me

usr.bin/morse/morse.c
297–301

I like this re-organization to avoid #undef ugliness... Please do mention it in the commit message

348

Can you rename this to Dflag to match the case of the flag, given that there's also a -d?

427

Can you throw these tokens in a separate #define up above as well? DELIMITERS or something to that effect.

Also, style(9) spaces around =

433

style(9) spaces around =

438

Inconsistent omission of braces around single-line clauses

605

Spaces around =

614

Spaces around =

620

Spaces around =

623

Spaces around =

626

Spaces around =

I have some nits to be picked. =p Please don't hate me

Review is great. Why would I hate you. Will fix

eadler marked 10 inline comments as done.

Thank you @kevans!

usr.bin/morse/morse.c
303–304

This doesn't seem to match the given commit message, which indicates that the flag was called -r

439

This one seems to have actually been missed; the braces should be omitted here like on the other one-line blocks.

I reckon this will be the last round. =)

usr.bin/morse/morse.c
349

These left more inconsistent omission of braces for single line blocks, but otherwise also a good change that should be noted in the commit message. =)

353

Here

356

Here

361

Here

369

Here

375

Here

378

Here

541

Here

547

Here

eadler marked 2 inline comments as done.
eadler added inline comments.
usr.bin/morse/morse.c
348

renamed to rflag to match dragongflybsd.

439

I went the reverse: adding braces to all single line blocks. style(9) makes it optional, I prefer it.

eadler marked 12 inline comments as done.Jan 6 2018, 6:42 AM
This revision is now accepted and ready to land.Jan 6 2018, 6:52 AM