Comments (5)
I've added a patch to ports tree to fix it:
https://svnweb.freebsd.org/ports/head/net/dpinger/files/patch-dpinger.c?revision=404730&view=markup
from dpinger.
Okay, thanks Renato.
Btw, I assume the ports tree doesn't allow conditional patches based on target version?
I added a temporary fix.
from dpinger.
Didn't you like the fcntl() fix?
from dpinger.
No, your fcntl() change was just fine. I was looking at all the descriptors for close on exec and ran into other problems. The remaining issue is the file descriptor from accept(). Since accept/fcntl isn't atomic, this fd is left exposed. I would like to use accept4(), but this has some issues on some Linux systems (you have to define __USE_GNU which I don't want to do), and isn't present in older FreeBSD systems. Given that I can't fix it completely on any system, I'm going to change it back to fcntl() in all locations and revisit it in a year.
After many years of coding for maximum portability and legacy systems, I've become tired of it. I have grown to absolutely hate ifdefs. :)
from dpinger.
I've pushed an update that covers all the FDs as best as can be done with fcntl(). Please let me know if you run into any other problems. Many thanks.
from dpinger.
Related Issues (18)
- dpinger doesn't work with source IPs specifying a scope ID HOT 1
- dpinger fails to start on IPv6 IPs considered "tentative" HOT 3
- Collecting Stats HOT 1
- pidfile not checked HOT 2
- Needs to support multiple targets HOT 1
- [FEATURE REQUEST] Multiple Targets HOT 1
- Negative numbers in parameters should be rejected
- Don't wait for send interval before sending first echo request
- Use accept4()
- Remove DISABLE_ACCEPT4 HOT 3
- Multiple targets revisited HOT 7
- Very handy app! But missing some features! HOT 9
- argument to define interface instead of ip HOT 1
- How to use it to check if public/external IP have changed and create an alert notification? HOT 1
- Add control over alarm decay intervals HOT 2
- Command not running on failure HOT 3
- readme file? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dpinger.