pantoniou / libfyaml

Fully feature complete YAML parser and emitter, supporting the latest YAML spec and passing the full YAML testsuite.
MIT License
239 stars 73 forks source link

The Redundant Code in fy-tool.c #96

Open Orange23333 opened 1 year ago

Orange23333 commented 1 year ago

https://github.com/pantoniou/libfyaml/blob/ce5149953e043541fb7ecca21691423aaad90513/src/tool/fy-tool.c#L1606C4-L1606C4

progname = argv[0];
progname = strrchr(argv[0], '/');

progname will always be modified by the second line. Is the first line of code redundant?

Orange23333 commented 1 year ago

PR #97 .