Skip to content

Commit

Permalink
Merge pull request masroore#11 from pjf/9_fail_multiread
Browse files Browse the repository at this point in the history
Have CurlMulti.InfoRead() fail when unimplemented.
  • Loading branch information
masroore committed Apr 22, 2015
2 parents c72c818 + a64a16d commit cfdbbbd
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions CurlSharp/CurlMulti.cs
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,8 @@ public int Select(int timeoutMillis)
}

/// <summary>
/// Obtain status information for a CurlMulti transfer.
/// Obtain status information for a CurlMulti transfer. Requires
/// CurlSharp be compiled with the libcurlshim helper.
/// </summary>
/// <returns>
/// An array of <see cref="CurlMultiInfo" /> objects, one for each
Expand Down Expand Up @@ -285,8 +286,17 @@ public CurlMultiInfo[] InfoRead()
}
NativeMethods.curl_shim_multi_info_free(pInfo);
}
#endif

return _multiInfo;

#else

throw new NotImplementedException(
"Sorry, CurlMulti.InfoRead is not implemented on this system."
);

#endif

}
}
}
}

0 comments on commit cfdbbbd

Please sign in to comment.