You've already forked linux-packaging-mono
Imported Upstream version 3.12.0
Former-commit-id: cf92446697332992ec36726e78eb8703e1f259d7
This commit is contained in:
@ -237,7 +237,6 @@ namespace System.ServiceModel.Description
|
||||
|
||||
for (int i = 0; i < contractMethods.Length; ++i)
|
||||
{
|
||||
|
||||
MethodInfo mi = contractMethods [i];
|
||||
OperationContractAttribute oca = GetOperationContractAttribute (mi);
|
||||
if (oca == null)
|
||||
@ -253,7 +252,7 @@ namespace System.ServiceModel.Description
|
||||
if (GetOperationContractAttribute (end) != null)
|
||||
throw new InvalidOperationException ("Async 'End' method must not have OperationContractAttribute. It is automatically treated as the EndMethod of the corresponding 'Begin' method.");
|
||||
}
|
||||
OperationDescription od = GetOrCreateOperation (cd, mi, serviceMethods [i], oca, end != null ? end.ReturnType : null, isCallback, givenServiceType);
|
||||
OperationDescription od = GetOrCreateOperation (cd, mi, serviceMethods [i], oca, end, isCallback, givenServiceType);
|
||||
if (end != null)
|
||||
od.EndMethod = end;
|
||||
}
|
||||
@ -286,7 +285,7 @@ namespace System.ServiceModel.Description
|
||||
static OperationDescription GetOrCreateOperation (
|
||||
ContractDescription cd, MethodInfo mi, MethodInfo serviceMethod,
|
||||
OperationContractAttribute oca,
|
||||
Type asyncReturnType,
|
||||
MethodInfo endMethod,
|
||||
bool isCallback,
|
||||
Type givenServiceType)
|
||||
{
|
||||
@ -311,7 +310,8 @@ namespace System.ServiceModel.Description
|
||||
|
||||
od.Messages.Add (GetMessage (od, mi, oca, true, isCallback, null));
|
||||
if (!od.IsOneWay) {
|
||||
var md = GetMessage (od, mi, oca, false, isCallback, asyncReturnType);
|
||||
var asyncReturnType = endMethod != null ? endMethod.ReturnType : null;
|
||||
var md = GetMessage (od, endMethod ?? mi, oca, false, isCallback, asyncReturnType);
|
||||
od.Messages.Add (md);
|
||||
var mpa = mi.ReturnParameter.GetCustomAttribute<MessageParameterAttribute> (true);
|
||||
if (mpa != null) {
|
||||
@ -522,8 +522,12 @@ namespace System.ServiceModel.Description
|
||||
int index = 0;
|
||||
foreach (ParameterInfo pi in plist) {
|
||||
// AsyncCallback and state are extraneous.
|
||||
if (oca.AsyncPattern && pi.Position == plist.Length - 2)
|
||||
break;
|
||||
if (oca.AsyncPattern) {
|
||||
if (isRequest && pi.Position == plist.Length - 2)
|
||||
break;
|
||||
if (!isRequest && pi.Position == plist.Length - 1)
|
||||
break;
|
||||
}
|
||||
|
||||
// They are ignored:
|
||||
// - out parameter in request
|
||||
|
Reference in New Issue
Block a user