forked from KolibriOS/kolibrios
HTTP library POST method example: use HTTP_send function
git-svn-id: svn://kolibrios.org@7008 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
df2ada42d5
commit
c115b27b86
@ -1,9 +1,10 @@
|
|||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
;; ;;
|
;; ;;
|
||||||
;; Copyright (C) KolibriOS team 2014-2015. All rights reserved. ;;
|
;; Copyright (C) KolibriOS team 2014-2017. All rights reserved. ;;
|
||||||
;; Distributed under terms of the GNU General Public License ;;
|
;; Distributed under terms of the GNU General Public License ;;
|
||||||
;; ;;
|
;; ;;
|
||||||
;; pasta.asm - Paste something to paste.kolibrios.org using POST ;;
|
;; post.asm - HTTP library example: ;;
|
||||||
|
;; Paste something to paste.kolibrios.org using HTTP POST method.;;
|
||||||
;; ;;
|
;; ;;
|
||||||
;; GNU GENERAL PUBLIC LICENSE ;;
|
;; GNU GENERAL PUBLIC LICENSE ;;
|
||||||
;; Version 2, June 1991 ;;
|
;; Version 2, June 1991 ;;
|
||||||
@ -83,8 +84,7 @@ START:
|
|||||||
jz error
|
jz error
|
||||||
mov [identifier], eax
|
mov [identifier], eax
|
||||||
|
|
||||||
mov ecx, [eax + http_msg.socket]
|
invoke HTTP_send, eax, sz_paste, sz_paste.length
|
||||||
mcall 75, 6, , sz_paste, sz_paste.length, 0
|
|
||||||
|
|
||||||
.again2:
|
.again2:
|
||||||
invoke HTTP_receive, [identifier]
|
invoke HTTP_receive, [identifier]
|
||||||
@ -145,6 +145,7 @@ import lib_http, \
|
|||||||
HTTP_post, 'post', \
|
HTTP_post, 'post', \
|
||||||
HTTP_receive, 'receive', \
|
HTTP_receive, 'receive', \
|
||||||
HTTP_find_header_field, 'find_header_field', \
|
HTTP_find_header_field, 'find_header_field', \
|
||||||
|
HTTP_send, 'send', \
|
||||||
HTTP_free, 'free'
|
HTTP_free, 'free'
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user