Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1507)

Side by Side Diff: pkg/analysis_server/lib/src/analysis_server.dart

Issue 698563003: Fix for an error in the error handler. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library analysis.server; 5 library analysis.server;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:collection'; 8 import 'dart:collection';
9 9
10 import 'package:analyzer/file_system/file_system.dart'; 10 import 'package:analyzer/file_system/file_system.dart';
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 return; 428 return;
429 } 429 }
430 if (response != null) { 430 if (response != null) {
431 channel.sendResponse(response); 431 channel.sendResponse(response);
432 return; 432 return;
433 } 433 }
434 } on RequestFailure catch (exception) { 434 } on RequestFailure catch (exception) {
435 channel.sendResponse(exception.response); 435 channel.sendResponse(exception.response);
436 return; 436 return;
437 } catch (exception, stackTrace) { 437 } catch (exception, stackTrace) {
438 RequestError error = 438 RequestError error = new RequestError(
439 new RequestError(RequestErrorCode.SERVER_ERROR, exception); 439 RequestErrorCode.SERVER_ERROR,
440 exception.toString());
440 if (stackTrace != null) { 441 if (stackTrace != null) {
441 error.stackTrace = stackTrace.toString(); 442 error.stackTrace = stackTrace.toString();
442 } 443 }
443 Response response = new Response(request.id, error: error); 444 Response response = new Response(request.id, error: error);
444 channel.sendResponse(response); 445 channel.sendResponse(response);
445 return; 446 return;
446 } 447 }
447 } 448 }
448 channel.sendResponse(new Response.unknownRequest(request)); 449 channel.sendResponse(new Response.unknownRequest(request));
449 }, onError: _sendServerErrorNotification); 450 }, onError: _sendServerErrorNotification);
(...skipping 495 matching lines...) Expand 10 before | Expand all | Expand 10 after
945 // send the notification 946 // send the notification
946 channel.sendNotification( 947 channel.sendNotification(
947 new ServerErrorParams( 948 new ServerErrorParams(
948 true, 949 true,
949 exceptionString, 950 exceptionString,
950 stackTraceString).toNotification()); 951 stackTraceString).toNotification());
951 } 952 }
952 } 953 }
953 954
954 typedef void OptionUpdater(AnalysisOptionsImpl options); 955 typedef void OptionUpdater(AnalysisOptionsImpl options);
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698