Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-10440

PATCH: Fix issues of ws2_32_new

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Fixed
    • Major
    • 0.4.3
    • Networking
    • September 2016

    Description

      I played around with ws2_32_new and managed to fix some bugs and make it working for me.

      A summary of ws2_32_new changes (the rest is described with each atomic commit) :

      • Don't use local variable for UpcallTable. Return error code from WSPStartup in WsTpAllocate. Add some checks
      • Fix reading PackedCatalogItem in WsTcEntryInitializeFromRegistry
      • Read protocol provider catalog from registry. Fix protocol range check in WsTcLoadProvider
      • Read namespace provider catalog from registry
      • Implement WSAEnumNamespaceProvidersA/W
      • Implement WSAEnumProvidersA/W based on WSCEnumProviders. Don't return protocol with iProtocol == 0 (based on winetest)
      • Some fixes in GetAddrInfoW according to the addrinfo wine tests
      • Use internal parsing of IPv4 address as the other function is more general (based on winetest)
      • Fix WSAStartup based on wine tests
      • Small fixes to getxyDataEnt
      • Add some checks to inet_addr based on wine tests
      • Add some checks and use dynamic memory for constructing DatabasePath in GetProtoOpenNetworkDatabase
      • Add error checks for namespace catalog entry list reading from registry
      • Add some checks in WSALookupService(Begin/Next/End) based on wine tests
      • Add some checks in setsockopt based on wine tests
      • Add some checks in WSASocketW based on wine tests
      • Fix DPRINT in sendto
      • Add some DPRINTs

      With attached patches I have the following results:
      ws2_32:getaddrinfo 397 tests executed (0 marked as todo, 119 failures), 0 skipped.
      ws2_32:ioctlsocket 19 tests executed (0 marked as todo, 2 failures), 0 skipped.
      ws2_32:nostartup 5 tests executed (0 marked as todo, 0 failures), 0 skipped.
      ws2_32:protocol 28 tests executed (0 marked as todo, 0 failures), 0 skipped.
      ws2_32:recv 19 tests executed (0 marked as todo, 0 failures), 0 skipped.
      ws2_32:sock 570181 tests executed (0 marked as todo, 179 failures), 11 skipped.
      ws2_32:WSAStartup 395 tests executed (0 marked as todo, 0 failures), 0 skipped.

      Here is the description of the patches:
      database.patch - adds protocol and network files, adds alias for mail protocol
      msafd.patch - small fixes to msafd that should be applicable even without ws2_32_new
      mswsock.patch - a copy of the patch that I attached to CORE-10024
      ws2_32_new.patch - my patch
      ws2_32_new_registry.patch - adds needed registry entries on tcpip install. should be applicable even now

      Please note that only small fixes are my work.
      Most of the work was already done by andy-123 and Alex.

      I hope for a good review.

      Attachments

        1. wsastartup.patch
          3 kB
        2. ws2_32.patch
          0.4 kB
        3. use_ws2_32_new.diff
          2 kB
        4. read_nscatalog.patch
          4 kB
        5. read_dcatalog.patch
          2 kB
        6. read_database.patch
          4 kB
        7. read_catalog_entry.patch
          4 kB
        8. read_bool.patch
          6 kB
        9. nsquery.c.r71208.patch
          0.5 kB
        10. mswsock.patch
          52 kB
        11. msafd.patch
          1 kB
        12. msafd_remove_fixed_catalog_entry_id.patch
          1 kB
        13. msafd_catalog_entry.patch
          5 kB
        14. move_upcall2.patch
          0.7 kB
        15. move_upcall1.patch
          4 kB
        16. inet_addr_invalid_param.patch
          0.9 kB
        17. hater-msafd-sockopt.patch
          1 kB
        18. get_set_opts.patch
          2 kB
        19. fix_getxyDataEnt.patch
          4 kB
        20. enumprotocols.patch
          3 kB
        21. disable_debug.patch
          7 kB
        22. dhcpcsvc_crash.txt
          0.6 kB
        23. database.patch
          12 kB
        24. CORE-10440-test-70247.zip
          256 kB
        25. CORE-10440-patchbot-r69893.patch
          57 kB
        26. CORE-10440+CORE-10533-2016_09_13.patch
          143 kB
        27. CORE-10440+CORE-10533-2016_09_10.patch
          111 kB
        28. bad_pointer.patch
          3 kB
        29. addrinfo2.patch
          1 kB
        30. addrinfo1.patch
          4 kB

        Issue Links

          Activity

            People

              AmineKhaldi AmineKhaldi
              hater hater
              Votes:
              6 Vote for this issue
              Watchers:
              13 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: