yatebts-sgsnggsn-inetutils-hostname-fix.diff 487 B

123456789101112131415
  1. diff --git a/mbts/SGSNGGSN/iputils.cpp b/mbts/SGSNGGSN/iputils.cpp
  2. index 979ae3a..49bb0ff 100644
  3. --- a/mbts/SGSNGGSN/iputils.cpp
  4. +++ b/mbts/SGSNGGSN/iputils.cpp
  5. @@ -466,7 +466,7 @@ EXPORT uint32_t *ip_findmyaddr()
  6. const int maxaddrs = 5;
  7. static uint32_t addrs[maxaddrs+1];
  8. int n = 0;
  9. - int fd = runcmd("|/bin/hostname","hostname","-I", NULL);
  10. + int fd = runcmd("|/bin/hostname","hostname","-i", NULL);
  11. if (fd < 0) {
  12. failed:
  13. addrs[0] = (unsigned) -1; // converts to all 1s