Subversion Repositories Kolibri OS

Rev

Rev 7300 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7300 Rev 9979
Line 1... Line 1...
1
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
1
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2
;;                                                                 ;;
2
;;                                                                 ;;
3
;; Copyright (C) KolibriOS team 2004-2018. All rights reserved.    ;;
3
;; Copyright (C) KolibriOS team 2004-2024. All rights reserved.    ;;
4
;; Distributed under terms of the GNU General Public License       ;;
4
;; Distributed under terms of the GNU General Public License       ;;
5
;;                                                                 ;;
5
;;                                                                 ;;
6
;;   Written by hidnplayr@kolibrios.org                            ;;
6
;;   Written by hidnplayr@kolibrios.org                            ;;
7
;;                                                                 ;;
7
;;                                                                 ;;
8
;;         GNU GENERAL PUBLIC LICENSE                              ;;
8
;;         GNU GENERAL PUBLIC LICENSE                              ;;
Line 224... Line 224...
224
        mov     ecx, eax
224
        mov     ecx, eax
225
        mov     esi, packetbuf                          ; esi = start pointer
225
        mov     esi, packetbuf                          ; esi = start pointer
226
  .nextcommand:
226
  .nextcommand:
227
        mov     edi, servercommand
227
        mov     edi, servercommand
228
  .byteloop:
228
  .byteloop:
-
 
229
        test    ecx, ecx
-
 
230
        jz      .nextpacket
229
        lodsb
231
        lodsb
-
 
232
        dec     ecx
230
        cmp     al, 10
233
        cmp     al, 10
231
        je      .got_command
234
        je      .got_command
232
        cmp     al, 13
235
        cmp     al, 13
233
        je      .got_command
236
        je      .got_command
234
        stosb
237
        stosb
235
        dec     ecx
-
 
236
        jnz     .byteloop
238
        jmp     .byteloop
237
        ;;; FIXME
-
 
238
        jmp     .nextpacket
-
 
Line 239... Line 239...
239
 
239
 
Line 240... Line 240...
240
; we have a command, call the serverparser
240
; we have a command, call the serverparser
-
 
241
 
-
 
242
  .got_command:
-
 
243
        cmp     edi, servercommand + 4
241
 
244
        jb      .nextcommand
242
  .got_command:
245
 
-
 
246
        mov     byte[edi], 0                            ; mark the end of the command
-
 
247
        push    esi ecx
243
        mov     byte[edi], 0                            ; mark the end of the command
248
        mov     ecx, edi
244
        push    esi ecx
249
        sub     ecx, servercommand                      ; put length in ecx
245
        call    server_parser
-
 
246
        pop     ecx esi
250
        call    server_parser
Line 247... Line 251...
247
        test    ecx, ecx
251
        pop     ecx esi
248
        jnz     .nextcommand
252
        jmp     .nextcommand
249
 
253