]> Git repositories of Nishi - repoview.git/commitdiff
trying to add multipart
authorNishi <nishi@nishi.boats>
Thu, 22 Aug 2024 03:43:42 +0000 (03:43 +0000)
committerNishi <nishi@nishi.boats>
Thu, 22 Aug 2024 03:43:42 +0000 (03:43 +0000)
git-svn-id: file:///raid/svn-personal/repoview/trunk@40 7e8b2a19-8934-dd40-8cb3-db22cdd5a80f

CGI/main.c

index f1b2803c1e14af4cdec0ed00e8c4661ee58e601f..e71687888a34826236f1936872b1f2f4da84a871 100644 (file)
@@ -52,7 +52,16 @@ int main() {
                                rv_error_http();
                                for(; type[i] != 0; i++) {
                                        if(type[i] != ' ' && type[i] != '\t') {
-                                               printf("%s\n", type + i);
+                                               int j;
+                                               char* boundary = type + i;
+                                               for(j = 0; boundary[j] != 0; j++){
+                                                       if(boundary[j] == '='){
+                                                               boundary[j] = 0;
+                                                               printf("%s\n%s\n", boundary, boundary + j + 1);
+                                                               found = true;
+                                                               break;
+                                                       }
+                                               }
                                                break;
                                        }
                                }