Unnamed: 0 int64 0 535k | source stringlengths 50 89.8k | target stringlengths 23 37.7k |
|---|---|---|
2,500 | CWE-000 <S2SV_StartBug> uint8_t vGetPinStatus ( uint8_t Port , int Pin ) { <S2SV_EndBug> return PinLibrary [ Port ] [ Pin ] ; } | <S2SV_ModStart> Pin ) { nInitializePinLibrary ( ) ; |
2,501 | CWE-000 int main ( int argc , char * argv [ ] ) { print_program_name ( ) ; print_license_header ( ) ; struct Args args = args_parser ( argc , argv ) ; print_problem_description ( args ) ; FILE * file ; char file_fitness [ ] = "DataVisualization/Fitness.csv" ; if ( args . write_fitness ) { file = fopen ( file_fitness , ... | <S2SV_ModStart> nextpopulation ; Individual * parent1 , * parent2 , * survivor , child <S2SV_ModEnd> ; GAResults results <S2SV_ModStart> n_queens ) ; <S2SV_ModEnd> free ( P |
2,502 | CWE-000 mat4 rotation_matrix ( float x , float y , float z ) { mat4 x_mat = new_mat4 ( ( float [ ] ) { 1.0f , 0.0f , 0.0f , 0.0f , 0.0f , cos ( x ) , - sin ( x ) , 0.0f , 0.0f , sin ( x ) , cos ( x ) , 0.0f , 0.0f , 0.0f , 0.0f , 1.0f } ) ; mat4 y_mat = new_mat4 ( ( float [ ] ) { cos ( y ) , 0.0f , sin ( y ) , 0.0f , 0... | <S2SV_ModStart> , cos ( y <S2SV_ModEnd> ) , 0.0f |
2,503 | CWE-000 DynaStatus dmap_remove ( DynaMap map , void * key ) { dmap * m = ( dmap * ) map ; DynaStatus status ; size_t idx = dmap_index ( m , key ) ; if ( idx != DMAP_INVALID_IDX ) { size_t ksize = m -> ksize ; size_t esize = m -> esize ; uint8_t * kptr = m -> keys + idx * ksize ; uint8_t * vptr = m -> map + idx * esize ... | <S2SV_ModStart> start ; } -- start ; <S2SV_ModStart> - idx ; if ( len > 0 ) { <S2SV_ModStart> vlen ) ; for ( size_t i = 0 ; i < len ; ++ i ) { infoptr [ i ] = infoptr [ i + 1 ] - 1 ; } <S2SV_ModEnd> memset ( kptr <S2SV_ModStart> esize ) ; } |
2,504 | CWE-000 void myroutine ( struct _myroutine_returns * _returns ) { struct _other_routine_returns _other_routine_get_returns ; _mi32 x = 0 ; _mi32 y = 0 ; _mi32 z = 0 ; <S2SV_StartBug> _mi32 V0 ; <S2SV_EndBug> _mi32 V1 ; _mi32 V2 ; other_routine ( & _other_routine_get_returns , 1 , 2 , x , y ) ; z = _other_routine_get_re... | <S2SV_ModStart> 0 ; _mi32 z2 = 0 ; _mi32 z3 = 0 ; _mi32 z4 = 0 ; _mi32 _V0 ; _mi32 _V1 ; _mi32 _V2 <S2SV_ModEnd> ; other_routine ( <S2SV_ModStart> . _returns_0 ; z2 = _other_routine_get_returns . _returns_1 ; z3 = _other_routine_get_returns . _returns_2 ; z4 = _other_routine_get_returns . _returns_3 ; _V0 <S2SV_ModEnd>... |
2,505 | CWE-000 static int ncm_bind ( struct usb_configuration * c , struct usb_function * f ) { struct usb_composite_dev * cdev = c -> cdev ; struct f_ncm * ncm = func_to_ncm ( f ) ; <S2SV_StartBug> struct usb_string * us ; <S2SV_EndBug> int status ; struct usb_ep * ep ; struct f_ncm_opts * ncm_opts ; if ( ! can_support_ecm (... | <S2SV_ModStart> usb_string * us = NULL |
2,506 | CWE-000 char * parse_path ( char * path , char * cwdPath ) { char * absPathname , * parsedPathname ; absPathname = __get_abspath ( path , cwdPath ) ; if ( absPathname != NULL ) { if ( ( strlen ( absPathname ) == 1 ) && ( absPathname [ 0 ] == '/' ) ) { <S2SV_StartBug> return absPathname ; <S2SV_EndBug> } parsedPathname ... | <S2SV_ModStart> ) ) { free ( absPathname ) ; return "/" <S2SV_ModEnd> ; } parsedPathname |
2,507 | CWE-000 ws2811_return_t ws2811_init ( ws2811_t * ws2811 ) { ws2811_device_t * device ; const rpi_hw_t * rpi_hw ; int chan ; ws2811 -> rpi_hw = rpi_hw_detect ( ) ; if ( ! ws2811 -> rpi_hw ) { return WS2811_ERROR_HW_NOT_SUPPORTED ; } rpi_hw = ws2811 -> rpi_hw ; ws2811 -> device = malloc ( sizeof ( * ws2811 -> device ) ) ... | <S2SV_ModStart> } channel -> gamma = malloc ( sizeof ( uint8_t ) * 256 ) ; int x ; for ( x = 0 ; x < 256 ; x ++ ) { channel -> gamma [ x ] = x ; } channel -> |
2,508 | CWE-000 int vmbus_device_register ( struct hv_device * child_device_obj ) { int ret = 0 ; dev_set_name ( & child_device_obj -> device , "%pUl" , child_device_obj -> channel -> offermsg . offer . if_instance . b ) ; child_device_obj -> device . bus = & hv_bus ; child_device_obj -> device . parent = & hv_acpi_dev -> dev ... | <S2SV_ModStart> = vmbus_device_release ; if ( is_hvsock_channel ( child_device_obj -> channel ) ) dev_set_uevent_suppress ( & child_device_obj -> device , 1 ) ; |
2,509 | CWE-000 static void prvSOCKETS_NonBlocking_Test ( Server_t xConn ) { BaseType_t xResult ; int32_t lNumBytes ; TickType_t xStartTime ; TickType_t xEndTime ; TickType_t xTimeout = 0 ; TickType_t xWaitTime = 1000 ; uint8_t * pucTxBuffer = ( uint8_t * ) cTxBuffer ; uint8_t * pucRxBuffer = ( uint8_t * ) cRxBuffer ; <S2SV_St... | <S2SV_ModStart> size_t xMessageLength = 500 <S2SV_ModEnd> ; size_t xNumBytesReceived |
2,510 | CWE-000 static int nat_callforwarding ( struct sk_buff * skb , struct nf_conn * ct , enum ip_conntrack_info ctinfo , unsigned int protoff , unsigned char * * data , int dataoff , TransportAddress * taddr , __be16 port , struct nf_conntrack_expect * exp ) { int dir = CTINFO2DIR ( ctinfo ) ; u_int16_t nated_port ; exp ->... | <S2SV_ModStart> nated_port ) ) <S2SV_ModEnd> ) { nf_ct_unexpect_related |
2,511 | CWE-000 bool get_sa_info ( struct state * st , bool inbound , deltatime_t * ago ) { char text_said [ SATOT_BUF ] ; u_int proto ; uint64_t bytes ; uint64_t add_time ; ipsec_spi_t spi ; const ip_address * src , * dst ; struct kernel_sa sa ; struct ipsec_proto_info * p2 ; const struct connection * c = st -> st_connection ... | <S2SV_ModStart> , DBG_log ( "get_sa_info<S2SV_blank>%s" <S2SV_ModEnd> , text_said ) |
2,512 | CWE-000 static void keyboardDongleProfileChangeCB ( uint8 paramID ) { uint8 newValue ; switch ( paramID ) { case KEYBOARD_PRESS_CHAR : KeyboardDongleProfile_GetParameter ( KEYBOARD_PRESS_CHAR , & newValue ) ; if ( newValue < 128 ) { uint8 hidCode = HIDTable [ newValue ] ; uint8 modifierCode = modifierTable [ newValue ]... | <S2SV_ModStart> 9 ] ; uint8 previousTypeData = 0 ; <S2SV_ModStart> { if ( previousTypeData == newValue ) if ( <S2SV_ModStart> ( USB_HID_KBD_EP , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ) ; } if ( hidReportBufLength < ( HID_REPORT_BUFFER_LEN - 1 ) ) { hidReportBufferAppend ( USB_HID_KBD_EP , <S2SV_ModStart> } } } previousTypeData... |
2,513 | CWE-000 static int out_create_mmap_buffer ( const struct audio_stream_out * stream , int32_t min_size_frames , struct audio_mmap_buffer_info * info ) { struct stream_out * out = ( struct stream_out * ) stream ; struct audio_device * adev = out -> dev ; int ret = 0 ; <S2SV_StartBug> unsigned int offset1 ; <S2SV_EndBug> ... | <S2SV_ModStart> unsigned int offset1 = 0 <S2SV_ModStart> unsigned int frames1 = 0 |
2,514 | CWE-000 static int tw686x_start_streaming ( struct vb2_queue * vq , unsigned int count ) { struct tw686x_video_channel * vc = vb2_get_drv_priv ( vq ) ; struct tw686x_dev * dev = vc -> dev ; struct pci_dev * pci_dev ; unsigned long flags ; int pb ; spin_lock_irqsave ( & dev -> lock , flags ) ; pci_dev = dev -> pci_dev ;... | <S2SV_ModStart> - ENODEV ; <S2SV_ModEnd> spin_lock_irqsave ( & |
2,515 | CWE-000 char checkVector3 ( const PVM vm , const PARRAY array ) { if ( array -> top != 3 ) { vm -> error ( vm , ERR_LEFT ERR_ARRAY ERR_ARRAY_SIZE_EXACT ( 3 ) , vm -> stack ) ; return 0 ; } for ( int i = 0 ; i < array -> top ; i ++ ) { if ( array -> data [ i ] -> type != SCALAR_TYPE ( ) ) { <S2SV_StartBug> vm -> error (... | <S2SV_ModStart> , ERR_CAN_ONLY_PROCESS ERR_SCALAR L"<S2SV_blank>" <S2SV_ModEnd> ERR_ARRAYS , vm |
2,516 | CWE-000 void pir_handler ( int32_t adc_val ) { log_printf ( "PIR<S2SV_blank>Handler\\n" ) ; <S2SV_StartBug> out_gen_stop ( ( bool * ) out_gen_end_all_on ) ; <S2SV_EndBug> <S2SV_StartBug> log_printf ( "Sensed<S2SV_blank>%d\\n" , adc_val ) ; <S2SV_EndBug> pir_disable ( ) ; <S2SV_StartBug> pir_oper_flag = true ; <S2SV_End... | <S2SV_ModStart> "PIR<S2SV_blank>Handler\\n" ) ; <S2SV_ModEnd> log_printf ( "Sensed<S2SV_blank>%d\\n" <S2SV_ModStart> adc_val ) ; { } <S2SV_ModStart> pir_oper_flag = true ; out_gen_stop ( ( bool * ) out_gen_end_all_on ) |
2,517 | CWE-000 static void bta_dm_process_remove_device ( BD_ADDR bd_addr , tBT_TRANSPORT transport ) { # if ( BLE_INCLUDED == TRUE && GATTC_INCLUDED == TRUE ) BTA_GATTC_CancelOpen ( 0 , bd_addr , FALSE ) ; # endif <S2SV_StartBug> BTM_SecDeleteDevice ( bd_addr ) ; <S2SV_EndBug> # if ( BLE_INCLUDED == TRUE && GATTC_INCLUDED ==... | <S2SV_ModStart> BTM_SecDeleteDevice ( bd_addr , transport |
2,518 | CWE-000 <S2SV_StartBug> int aac_send_hosttime ( struct aac_dev * dev , struct timeval * now ) <S2SV_EndBug> { int ret = - ENOMEM ; struct fib * fibptr ; __le32 * info ; fibptr = aac_fib_alloc ( dev ) ; if ( ! fibptr ) goto out ; aac_fib_init ( fibptr ) ; info = ( __le32 * ) fib_data ( fibptr ) ; * info = cpu_to_le32 ( ... | <S2SV_ModStart> dev , struct timespec64 <S2SV_ModEnd> * now ) |
2,519 | CWE-000 static int chcr_cra_init ( struct crypto_tfm * tfm ) { struct crypto_alg * alg = tfm -> __crt_alg ; struct chcr_context * ctx = crypto_tfm_ctx ( tfm ) ; struct ablk_ctx * ablkctx = ABLK_CTX ( ctx ) ; ablkctx -> sw_cipher = crypto_alloc_skcipher ( alg -> cra_name , 0 , CRYPTO_ALG_ASYNC | CRYPTO_ALG_NEED_FALLBACK... | <S2SV_ModStart> ) ; } if ( get_cryptoalg_subtype ( tfm ) == CRYPTO_ALG_SUB_TYPE_XTS ) { ablkctx -> aes_generic = crypto_alloc_cipher ( "aes-generic" , 0 , 0 ) ; if ( IS_ERR ( ablkctx -> aes_generic ) ) { pr_err ( "failed<S2SV_blank>to<S2SV_blank>allocate<S2SV_blank>aes<S2SV_blank>cipher<S2SV_blank>for<S2SV_blank>tweak\... |
2,520 | CWE-000 struct seccomp_config * scconfig_init ( ) { struct seccomp_config * cfg = malloc ( sizeof ( struct seccomp_config ) ) ; <S2SV_StartBug> if ( cfg != NULL ) { <S2SV_EndBug> PFTL ( "malloc<S2SV_blank>memory" ) ; return NULL ; } cfg -> type = CFG_WHITELIST ; cfg -> deny_action = DENY_KILL ; cfg -> rules_count = 0 ;... | <S2SV_ModStart> if ( cfg == <S2SV_ModEnd> NULL ) { |
2,521 | CWE-000 genome_t * genome_load_chromosome ( genome_t * genome , char * chromosome_name ) { if ( ! genome -> chromosome ) { if ( ! ( genome -> chromosome = ( chromosome_t * ) malloc ( sizeof ( chromosome_t ) ) ) ) { fprintf ( stdout , "[ERROR]<S2SV_blank>can\'t<S2SV_blank>allocate\\n" ) ; return NULL ; } genome -> chrom... | <S2SV_ModStart> ) ; } <S2SV_ModEnd> int index ; <S2SV_ModStart> fp ) ; <S2SV_ModEnd> return genome ; |
2,522 | CWE-000 int main ( ) { int r ; char * t1 = "abcabc" ; size_t tl1 = strlen ( t1 ) ; char * t2 = "a" ; size_t tl2 = strlen ( t2 ) ; char * t3 = "ab" ; size_t tl3 = strlen ( t3 ) ; char * s0 = "" ; char * a = "a" ; char * b = "b" ; char * c = "c" ; char * ab = "ab" ; char * abc = "abc" ; char * aaa = "aaa" ; char * ac = "... | <S2SV_ModStart> ) ) ; <S2SV_ModEnd> printf ( "/(abc)|(ac)/\\t[%s]?\\t%d\\n" |
2,523 | CWE-000 static void process_event ( struct a12_state * S , void * tag , void ( * on_event ) ( struct arcan_shmif_cont * wnd , int chid , struct arcan_event * , void * ) ) { if ( ! process_mac ( S ) ) <S2SV_StartBug> return ; <S2SV_EndBug> struct arcan_event aev ; unpack_u64 ( & S -> last_seen_seqnr , S -> decode ) ; if... | <S2SV_ModStart> ) ) return ; uint8_t channel = S -> decode [ 16 ] <S2SV_ModStart> ( on_event ) { debug_print ( 2 , "unpack<S2SV_blank>event<S2SV_blank>to<S2SV_blank>%d" , channel ) ; on_event ( S -> channels [ channel ] . cont <S2SV_ModEnd> , 0 , <S2SV_ModStart> tag ) ; } |
2,524 | CWE-000 int deleteTest ( ) { FILE * fp , * ftemp ; student s1 ; fp = fopen ( "students.dat" , "rb" ) ; ftemp = fopen ( "temp.dat" , "wb" ) ; int chosenTest = testsMenu ( ) - 1 ; if ( chosenTest == - 1 ) { return 0 ; } ; printf ( "\\nVoce<S2SV_blank>tem<S2SV_blank>certeza<S2SV_blank>que<S2SV_blank>gostaria<S2SV_blank>de... | <S2SV_ModStart> { return 0 ; } else { printf ( "\\nProva<S2SV_blank>excluida." ) <S2SV_ModStart> fp ) ; printf ( "\\n\\nPressione<S2SV_blank>ENTER<S2SV_blank>para<S2SV_blank>continuar<S2SV_blank>" ) ; getchar ( ) ; |
2,525 | CWE-000 int in_bounds ( pos position ) { <S2SV_StartBug> int x , y ; <S2SV_EndBug> x = position . x ; y = position . y ; <S2SV_StartBug> if ( x < 8 && x >= 0 && y < 8 && y >= 0 ) <S2SV_EndBug> return TRUE ; return FALSE ; } | <S2SV_ModStart> position ) { if ( position . <S2SV_ModEnd> x < 8 <S2SV_ModStart> < 8 && position . <S2SV_ModStart> >= 0 && position . <S2SV_ModStart> < 8 && position . |
2,526 | CWE-000 static gint save_setting ( chassis * srv , gint * effected_rows ) { gint ret = ASSIGN_OK ; GKeyFile * keyfile = g_key_file_new ( ) ; g_key_file_set_list_separator ( keyfile , ',' ) ; GString * free_path = g_string_new ( NULL ) ; if ( srv -> default_file == NULL ) { gchar * current_dir = g_get_current_dir ( ) ; ... | <S2SV_ModStart> ) ; } else { if ( ( ret = chmod ( srv -> default_file , S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP ) ) ) { g_debug ( "remove<S2SV_blank>operate<S2SV_blank>failed,<S2SV_blank>filename:%s,<S2SV_blank>errno:%d" , ( srv -> default_file == NULL ? "" : srv -> default_file ) , errno ) ; ret = CHMOD_ERROR ; } } |
2,527 | CWE-000 void CreeperModel_DrawModel ( Entity * entity ) { Gfx_BindTexture ( IModel_GetTexture ( & CreeperModel , entity -> MobTextureId ) ) ; IModel_DrawRotate ( - entity -> HeadX * MATH_DEG2RAD , 0.0f , 0.0f , Head , true ) ; IModel_DrawPart ( Torso ) ; <S2SV_StartBug> IModel_DrawRotate ( entity -> anim . leftLegX , 0... | <S2SV_ModStart> ( entity -> Anim . LeftLegX <S2SV_ModEnd> , 0.0f , <S2SV_ModStart> ( entity -> Anim . RightLegX <S2SV_ModEnd> , 0.0f , <S2SV_ModStart> ( entity -> Anim . RightLegX <S2SV_ModEnd> , 0.0f , <S2SV_ModStart> ( entity -> Anim . LeftLegX <S2SV_ModEnd> , 0.0f , |
2,528 | CWE-000 static int get_format ( int fd , enum v4l2_buf_type buf_type ) { struct v4l2_format fmt ; int port ; int rc ; <S2SV_StartBug> int extra_idx = 0 ; <S2SV_EndBug> int extra_data_size = 0 ; memset ( & fmt , 0 , sizeof ( fmt ) ) ; fmt . type = buf_type ; rc = ioctl ( fd , VIDIOC_G_FMT , & fmt ) ; if ( rc ) { E ( "Fa... | <S2SV_ModStart> int rc ; unsigned |
2,529 | CWE-000 static void stream_fd_closed ( int fd , void * p , uintptr_t u ) { struct stream_fd * sfd = p ; struct call * c ; int i ; socklen_t j ; assert ( sfd -> socket . fd == fd ) ; c = sfd -> call ; if ( ! c ) return ; j = sizeof ( i ) ; <S2SV_StartBug> getsockopt ( fd , SOL_SOCKET , SO_ERROR , & i , & j ) ; <S2SV_End... | <S2SV_ModStart> i ) ; i = 0 ; |
2,530 | CWE-000 SP_API enum sp_return sp_blocking_write ( struct sp_port * port , const void * buf , size_t count , unsigned int timeout_ms ) { TRACE ( "%p,<S2SV_blank>%p,<S2SV_blank>%d,<S2SV_blank>%d" , port , buf , count , timeout_ms ) ; CHECK_OPEN_PORT ( ) ; if ( ! buf ) RETURN_ERROR ( SP_ERR_ARG , "Null<S2SV_blank>buffer" ... | <S2SV_ModStart> ; if ( count == 0 ) RETURN_ERROR ( SP_ERR_ARG , "Zero<S2SV_blank>count" ) ; if ( <S2SV_ModStart> ) DEBUG_FMT ( "Writing<S2SV_blank>up<S2SV_blank>to<S2SV_blank>%d<S2SV_blank>bytes<S2SV_blank>to<S2SV_blank>port<S2SV_blank>%s,<S2SV_blank>timeout<S2SV_blank>%d<S2SV_blank>ms" <S2SV_ModEnd> , count , <S2SV_Mo... |
2,531 | CWE-000 void demo ( char * text , unsigned len ) { kdgu * q = kdgu_new ( KDGU_FMT_UTF32 , text , len ) ; <S2SV_StartBug> kdgu_chomp ( q ) ; <S2SV_EndBug> kdgu_uc ( q ) ; kdgu_reverse ( q ) ; kdgu_convert ( q , KDGU_FMT_UTF8 ) ; kdgu * r = kdgu_copy ( q ) ; kdgu_convert ( r , KDGU_FMT_UTF16 ) ; <S2SV_StartBug> kdgu_conv... | <S2SV_ModStart> len ) ; kdgu_convert ( q , KDGU_FMT_UTF16 ) ; <S2SV_ModStart> r , KDGU_FMT_UTF8 <S2SV_ModEnd> ) ; # |
2,532 | CWE-000 static bool rx_complete_cb ( struct _dw1000_dev_instance_t * inst , dw1000_mac_interface_t * cbs ) { tdma_instance_t * tdma = inst -> tdma ; <S2SV_StartBug> if ( inst -> fctrl_array [ 0 ] == FCNTL_IEEE_BLINK_CCP_64 ) { <S2SV_EndBug> <S2SV_StartBug> DIAGMSG ( "{\\"utime\\":<S2SV_blank>%lu,\\"msg\\":<S2SV_blank>\... | <S2SV_ModStart> ( inst -> ccp -> status . valid && inst -> <S2SV_ModStart> { DIAGMSG ( "{\\"utime\\":<S2SV_blank>%lu,\\"msg\\":<S2SV_blank>\\"tdma:rx_complete_cb\\"}\\n" <S2SV_ModEnd> , os_cputime_ticks_to_usecs ( |
2,533 | CWE-000 __attribute__ ( ( nonnull ( 1 ) , nothrow , warn_unused_result ) ) static int test1 ( darr_t * restrict darr , size_t nnum ) { size_t k ; size_t snum = ( size_t ) rand ( ) % nnum ; size_t sz = darr -> n ; int * restrict nums ; fprintf ( stderr , "test1<S2SV_blank>()<S2SV_blank>snum:<S2SV_blank>%d,<S2SV_blank>sz... | <S2SV_ModStart> { fputs ( "error<S2SV_blank>-11" , stderr <S2SV_ModEnd> ) ; fflush |
2,534 | CWE-000 static void test_keyrelease ( void * * state ) { <S2SV_StartBug> ( void ) state ; <S2SV_EndBug> input . lastState = KEY_UP ; input . currentState = 0 ; assert_true ( key_is_released ( & input , KEY_UP ) ) ; } | <S2SV_ModStart> void ) state ; KeyboardInput input = { 0 , 0 } |
2,535 | CWE-000 static void do_alloc ( int argc , char * argv [ ] ) { if ( argc != 3 ) { printf ( "usage:<S2SV_blank>./array<S2SV_blank><file-name><S2SV_blank>alloc<S2SV_blank><array-name>" "<size><S2SV_blank><type>\\n" ) ; return ; } enum array_types type = get_type ( argv [ 2 ] ) ; if ( type == UNKNOWN_ARRAY_TYPE ) return ; ... | <S2SV_ModStart> array_info ) ; strncpy <S2SV_ModEnd> ( info -> <S2SV_ModStart> 0 ] , MAX_BUFFLEN ) ; info -> name [ MAX_BUFFLEN - 1 ] = '\\0' <S2SV_ModEnd> ; info -> |
2,536 | CWE-000 int start_listener ( ) { int sock ; <S2SV_StartBug> if ( strcasecmp ( "true" , getenv ( "USE_NETWORK" ) ) == 0 || <S2SV_EndBug> <S2SV_StartBug> strcasecmp ( "yes" , getenv ( "USE_NETWORK" ) ) == 0 ) { <S2SV_EndBug> sock = start_listener_inet ( ) ; } else { sock = start_listener_ipc ( & uds_client_fn ) ; atexit ... | <S2SV_ModStart> int sock ; char * network ; if ( getenv ( "USE_NETWORK" ) == NULL ) { network = "no" ; lprintf ( WARNING , "USE_NETWORK<S2SV_blank>is<S2SV_blank>not<S2SV_blank>set,<S2SV_blank>use<S2SV_blank>default<S2SV_blank>value<S2SV_blank>\\"no\\"." ) ; } else { network = getenv ( "USE_NETWORK" ) ; } <S2SV_ModStart... |
2,537 | CWE-000 static GstRTSPResult rtsp_ext_real_stream_select ( GstRTSPExtension * ext , GstRTSPUrl * url ) { GstRTSPReal * ctx = ( GstRTSPReal * ) ext ; GstRTSPResult res ; GstRTSPMessage request = { 0 } ; GstRTSPMessage response = { 0 } ; gchar * req_url ; if ( ! ctx -> isreal ) return GST_RTSP_OK ; if ( ! ctx -> rules ) ... | <S2SV_ModStart> ) ) ; g_free ( req_url ) ; |
2,538 | CWE-000 jactivity_t * activity_new ( activity_table_t * at , char * actid , bool remote ) { jactivity_t * jact = ( jactivity_t * ) calloc ( 1 , sizeof ( jactivity_t ) ) ; if ( jact != NULL ) { <S2SV_StartBug> jact -> remote = remote ; <S2SV_EndBug> jact -> resultq = pqueue_new ( false ) ; while ( ( jact -> thread = act... | <S2SV_ModStart> remote = remote <S2SV_ModEnd> ; while ( |
2,539 | CWE-000 <S2SV_StartBug> int imap_access ( const char * path , int flags ) <S2SV_EndBug> { struct ImapData * idata = NULL ; struct ImapMbox mx ; char buf [ LONG_STRING ] ; char mailbox [ LONG_STRING ] ; char mbox [ LONG_STRING ] ; int rc ; if ( imap_parse_path ( path , & mx ) ) return - 1 ; if ( ! ( idata = imap_conn_fi... | <S2SV_ModStart> char * path <S2SV_ModEnd> ) { struct |
2,540 | CWE-000 static int __wlan_hdd_cfg80211_firmware_roaming ( struct wiphy * wiphy , struct wireless_dev * wdev , const void * data , int data_len ) { u8 bssid [ 6 ] = { 0 } ; hdd_context_t * pHddCtx = wiphy_priv ( wiphy ) ; struct nlattr * tb [ QCA_WLAN_VENDOR_ATTR_MAX + 1 ] ; eHalStatus status = eHAL_STATUS_SUCCESS ; v_U... | <S2SV_ModStart> EINVAL ; } if ( nla_len ( tb [ QCA_WLAN_VENDOR_ATTR_MAC_ADDR ] ) < sizeof ( bssid ) ) { hddLog ( VOS_TRACE_LEVEL_ERROR , FL ( "Attribute<S2SV_blank>peerMac<S2SV_blank>is<S2SV_blank>invalid=%d" ) , adapter -> device_mode ) ; return - EINVAL ; } |
2,541 | CWE-000 static int add_parents_to_list ( struct rev_info * revs , struct commit * commit , struct commit_list * * list , struct commit_list * * cache_ptr ) { struct commit_list * parent = commit -> parents ; unsigned left_flag ; struct commit_list * cached_base = cache_ptr ? * cache_ptr : NULL ; if ( commit -> object .... | <S2SV_ModStart> -> item ; int gently = revs -> ignore_missing_links || revs -> exclude_promisor_objects ; <S2SV_ModStart> ( p , gently <S2SV_ModEnd> ) < 0 <S2SV_ModStart> < 0 ) { if ( revs -> exclude_promisor_objects && is_promisor_object ( & p -> object . oid ) ) { if ( revs -> first_parent_only ) break ; continue ; }... |
2,542 | CWE-000 int nat_rebinding_test ( ) { uint64_t simulated_time = 0 ; uint64_t loss_mask = 0 ; uint64_t initial_challenge = 0 ; picoquic_test_tls_api_ctx_t * test_ctx = NULL ; int ret = tls_api_init_ctx ( & test_ctx , PICOQUIC_INTERNAL_TEST_VERSION_1 , <S2SV_StartBug> PICOQUIC_TEST_SNI , PICOQUIC_TEST_ALPN , & simulated_t... | <S2SV_ModStart> 0 ) ; if ( ret == 0 ) { ret = tls_api_connection_loop ( test_ctx , & loss_mask , 0 , & simulated_time ) ; } |
2,543 | CWE-000 int main ( void ) { <S2SV_StartBug> init ( ) ; <S2SV_EndBug> Driver * driver [ NUMBER_PORTS ] = { NULL , NULL } ; ContollerData cd [ NUMBER_PORTS ] ; Joystick joystick [ NUMBER_PORTS ] = { 0 , 0 } ; # if SINGLE_CONTROLLER == CONTROLLER_A for ( uint8_t p = PORT_A ; p <= PORT_A ; p ++ ) { # elif SINGLE_CONTROLLER... | <S2SV_ModStart> { init ( ) ; led_switch ( LED_BLINK1 <S2SV_ModStart> ) ; } led_switch ( LED_OFF ) ; |
2,544 | CWE-000 static MonoImage * do_mono_image_load ( MonoImage * image , MonoImageOpenStatus * status , gboolean care_about_cli , gboolean care_about_pecoff ) { ERROR_DECL ( error ) ; MonoCLIImageInfo * iinfo ; MonoDotNetHeader * header ; GSList * l ; MONO_PROFILER_RAISE ( image_loading , ( image ) ) ; mono_image_init ( ima... | <S2SV_ModStart> -> ref_only && mono_is_problematic_image <S2SV_ModEnd> ( image ) |
2,545 | CWE-000 <S2SV_StartBug> static inline bool AlarmShallStrike ( uint32_t aNow , AlarmIndex aIndex ) <S2SV_EndBug> { <S2SV_StartBug> uint32_t diff = aNow - sTimerData [ aIndex ] . mTargetTime ; <S2SV_EndBug> <S2SV_StartBug> return ! ( ( diff & ( 1UL << 31 ) ) != 0 ) ; <S2SV_EndBug> } | <S2SV_ModStart> bool AlarmShallStrike ( uint64_t <S2SV_ModEnd> aNow , AlarmIndex <S2SV_ModStart> aIndex ) { return aNow >= <S2SV_ModEnd> sTimerData [ aIndex <S2SV_ModStart> . mTargetTime ; <S2SV_ModEnd> } <S2SV_null> <S2SV_null> |
2,546 | CWE-000 s64 garbage_collect ( ) { HashsetIterator hti ; s64 mem1 = heap_size ; s64 del = 0 ; s64 time_startAt ; time_startAt = currentTimeMillis ( ) ; garbage_thread_lock ( ) ; if ( garbage_pause_the_world ( ) != 0 ) { garbage_resume_the_world ( ) ; return - 1 ; } garbage_move_cache ( ) ; garbage_copy_refer ( ) ; garba... | <S2SV_ModStart> ( ) ; <S2SV_ModEnd> s64 time_stopWorld = <S2SV_ModStart> time_startAt = currentTimeMillis ( ) ; _garbage_change_flag <S2SV_ModStart> flag_refer ) { garbage_destory_memobj ( mb ) ; hashset_iter_remove ( & hti <S2SV_ModEnd> ) ; del <S2SV_ModStart> ) ; } garbage_thread_unlock ( ) ; |
2,547 | CWE-000 static void gsi_handle_ev_ctrl ( int ee ) { uint32_t ch ; int i ; uint32_t val ; struct gsi_evt_ctx * ctx ; ch = gsi_readl ( gsi_ctx -> base + GSI_EE_n_CNTXT_SRC_EV_CH_IRQ_OFFS ( ee ) ) ; GSIDBG ( "ev<S2SV_blank>%x\\n" , ch ) ; for ( i = 0 ; i < 32 ; i ++ ) { <S2SV_StartBug> if ( ( 1 << i ) & ch ) { <S2SV_EndBu... | <S2SV_ModStart> ch ) { if ( i >= gsi_ctx -> max_ev || i >= GSI_EVT_RING_MAX ) { GSIERR ( "invalid<S2SV_blank>event<S2SV_blank>%d\\n" , i ) ; break ; } |
2,548 | CWE-000 static void cpuset_css_free ( struct cgroup * cont ) { struct cpuset * cs = cgroup_cs ( cont ) ; free_cpumask_var ( cs -> cpus_allowed ) ; <S2SV_StartBug> kfree ( cs ) ; <S2SV_EndBug> } | <S2SV_ModStart> cpus_allowed ) ; free_cpumask_var ( cs -> cpus_requested ) ; |
2,549 | CWE-000 <S2SV_StartBug> static void list_lttng_channels ( enum lttng_domain_type domain , <S2SV_EndBug> struct ltt_session * session , struct lttng_channel * channels , struct lttcomm_channel_extended * chan_exts ) { <S2SV_StartBug> int i = 0 , ret ; <S2SV_EndBug> struct ltt_kernel_channel * kchan ; DBG ( "Listing<S2SV... | <S2SV_ModStart> <S2SV_null> <S2SV_null> static ssize_t <S2SV_ModEnd> list_lttng_channels ( enum <S2SV_ModStart> 0 , ret = 0 <S2SV_ModStart> break ; } chan_exts [ i ] . monitor_timer_interval = uchan -> monitor_timer_interval ; <S2SV_ModStart> } end : if ( ret < 0 ) { return - LTTNG_ERR_FATAL ; } else { return LTTNG_OK ... |
2,550 | CWE-000 void time_of_add_dynamic ( int amount ) { struct timeval real_start , real_end ; struct rusage susage , eusage ; <S2SV_StartBug> int block_size = arc4random ( ) % ( MAX_BLOCK_SIZE - 1 ) + 1 ; <S2SV_EndBug> dynamic_array * array = create_random_dynamic_array ( amount , block_size ) ; char * block = create_block ... | <S2SV_ModStart> ; int block_size ; do { block_size <S2SV_ModStart> ) + 1 ; } while ( ( block_size ) % 16 == 0 ) |
2,551 | CWE-000 static void btm_ble_process_adv_pkt_cont ( BD_ADDR bda , UINT8 addr_type , UINT8 evt_type , UINT8 * p ) { tINQ_DB_ENT * p_i ; tBTM_INQUIRY_VAR_ST * p_inq = & btm_cb . btm_inq_vars ; tBTM_INQ_RESULTS_CB * p_inq_results_cb = p_inq -> p_inq_results_cb ; tBTM_INQ_RESULTS_CB * p_obs_results_cb = btm_cb . ble_ctr_cb ... | <S2SV_ModStart> BTM_BLE_SCAN_DUPLICATE_ENABLE ) { int same_addr = <S2SV_ModEnd> memcmp ( bda <S2SV_ModStart> , BD_ADDR_LEN ) ; if ( same_addr != 0 || ( same_addr == 0 && evt_type != BTM_BLE_SCAN_RSP_EVT ) <S2SV_ModEnd> ) { btm_ble_process_last_adv_pkt |
2,552 | CWE-000 int iupdrvFontGetStringWidth ( Ihandle * ih , const char * str ) { <S2SV_StartBug> return emjsFont_GetStringWidth ( ih -> handle -> handleID , str ) ; <S2SV_EndBug> } | <S2SV_ModStart> str ) { iupEmscripten_Log ( "iupdrvFontGetStringWidth<S2SV_blank>being<S2SV_blank>called" ) ; <S2SV_ModStart> return emjsFont_GetStringWidth ( ih , |
2,553 | CWE-000 static bool too_many_workers ( struct worker_pool * pool ) { bool managing = mutex_is_locked ( & pool -> manager_arb ) ; int nr_idle = pool -> nr_idle + managing ; int nr_busy = pool -> nr_workers - nr_idle ; <S2SV_StartBug> if ( list_empty ( & pool -> idle_list ) ) <S2SV_EndBug> return false ; return nr_idle >... | <S2SV_ModStart> - nr_idle ; <S2SV_ModEnd> return nr_idle > |
2,554 | CWE-000 void hangouts_get_conversation_events ( HangoutsAccount * ha , const gchar * conv_id , gint64 since_timestamp ) { GetConversationRequest request ; ConversationId conversation_id ; <S2SV_StartBug> ConversationSpec conversation_spec ; <S2SV_EndBug> get_conversation_request__init ( & request ) ; request . request_... | <S2SV_ModStart> ; ConversationSpec conversation_spec ; EventContinuationToken event_continuation_token <S2SV_ModStart> 0 ) { <S2SV_ModEnd> request . has_include_event |
2,555 | CWE-000 int main ( int argc , char * * argv ) { int i ; time_t seconds ; unsigned int reverse_seconds ; int result ; struct tm * breakdown ; char out_string [ 13 ] ; int last_minute = - 1 ; unsigned char big_display [ 16 ] ; int digit ; # if 0 struct tm { int tm_sec ; int tm_min ; int tm_hour ; int tm_mday ; int tm_mon... | <S2SV_ModStart> NULL ) ; breakdown = localtime ( & seconds ) ; <S2SV_ModStart> & 0xff , ( 1 << ( ( breakdown -> tm_sec / 6 ) + 1 ) ) - 1 <S2SV_ModEnd> , ( reverse_seconds <S2SV_ModStart> & 0xff , ( 1 << ( ( breakdown -> tm_sec / 6 ) + 1 ) ) - 1 <S2SV_ModEnd> ) ; if |
2,556 | CWE-000 VOID OvsConntrackEntryCleaner ( PVOID data ) { POVS_CT_THREAD_CTX context = ( POVS_CT_THREAD_CTX ) data ; PLIST_ENTRY link , next ; POVS_CT_ENTRY entry ; <S2SV_StartBug> BOOLEAN success = TRUE ; <S2SV_EndBug> while ( success ) { <S2SV_StartBug> LOCK_STATE_EX lockState ; <S2SV_EndBug> NdisAcquireRWLockWrite ( ov... | <S2SV_ModStart> POVS_CT_ENTRY entry ; LOCK_STATE_EX lockState ; <S2SV_ModStart> success ) { if ( ovsConntrackLockObj == NULL ) { break ; } <S2SV_ModEnd> NdisAcquireRWLockWrite ( ovsConntrackLockObj |
2,557 | CWE-000 static void write_u16 ( int fd , uint16_t len , char * status ) { <S2SV_StartBug> char buf [ ARGSIZE ] = { ( len & ( 255 << 8 ) ) >> 8 , len & 255 } ; <S2SV_EndBug> if ( write ( fd , buf , ARGSIZE ) != ARGSIZE ) { * status = ERR_WRITE ; } } | <S2SV_ModStart> ] = { HBYTE ( len ) , LBYTE ( len ) <S2SV_ModEnd> } ; if |
2,558 | CWE-000 <S2SV_StartBug> void fCeedQFunctionSetContext ( int * qf , void * ctx , size_t * ctxsize , <S2SV_EndBug> int * err ) { CeedQFunction qf_ = CeedQFunction_dict [ * qf ] ; <S2SV_StartBug> struct fContext * newFContext ; CeedMalloc ( 1 , & newFContext ) ; <S2SV_EndBug> newFContext -> f = ( ( struct fContext * ) ( q... | <S2SV_ModStart> <S2SV_null> <S2SV_null> void fCeedQFunctionAddInput <S2SV_ModEnd> ( int * <S2SV_ModStart> * qf , const char * fieldname , CeedInt * ncomp , CeedEvalMode * emode , <S2SV_ModEnd> int * err <S2SV_ModStart> qf ] ; <S2SV_ModEnd> * err = <S2SV_ModStart> * err = CeedQFunctionAddInput <S2SV_ModEnd> ( qf_ , <S2S... |
2,559 | CWE-000 void my_connect_callback ( struct mosquitto * mosq , void * obj , int result ) { int i ; struct mosq_config * cfg ; assert ( obj ) ; cfg = ( struct mosq_config * ) obj ; if ( ! result ) { <S2SV_StartBug> mosquitto_subscribe ( mosq , NULL , "a/b" , 0 ) ; <S2SV_EndBug> } else { zsys_error ( "%s\\n" , mosquitto_co... | <S2SV_ModStart> , "a/b" , 2 <S2SV_ModEnd> ) ; } |
2,560 | CWE-000 superframe_t * channels_generate_superframe ( const channel_t * const m_channel_list ) { superframe_entry_t * sf = calloc ( channels_count + 1 , sizeof ( superframe_entry_t ) ) ; unsigned int sf_size = 0 ; int rate = 0 ; for ( rate = 0 ; rate < RATE_END ; rate ++ ) { superframe_offset [ rate ] = sf_size ; sf_si... | <S2SV_ModStart> = '\\0' ; printf ( "Finished<S2SV_blank>generating<S2SV_blank>superframe<S2SV_blank>entries\\n" ) ; |
2,561 | CWE-000 void rump_booter_init ( void * d ) { printc ( "~~~~~<S2SV_blank>vmid:<S2SV_blank>%d<S2SV_blank>~~~~~\\n" , vmid ) ; assert ( vmid == 0 ) ; printc ( "\\nRumpKernel<S2SV_blank>Boot<S2SV_blank>Start.\\n" ) ; cos2rump_setup ( ) ; rk_sched_init ( RK_SCHED_PERIOD_US ) ; printc ( "\\nSetting<S2SV_blank>up<S2SV_blank>a... | <S2SV_ModStart> ; rk_alloc_run ( RK_JSON_DEFAULT_QEMU <S2SV_ModEnd> ) ; printc |
2,562 | CWE-000 Tree * createTree ( Tree * tree , int * number ) { Tree * temp = newEmptyTree ( ) ; if ( temp == NULL ) { printf ( "createTree<S2SV_blank>ERROR:<S2SV_blank>not<S2SV_blank>possible<S2SV_blank>to<S2SV_blank>create<S2SV_blank>new<S2SV_blank>temp<S2SV_blank>empty<S2SV_blank>tree\\n\\n" ) ; return NULL ; } temp = tr... | <S2SV_ModStart> tree -> root = newEmptyNode ( ) ; tree -> root |
2,563 | CWE-000 int BsdTcpServer ( unsigned short usPort ) { SlSockAddrIn_t sAddr ; SlSockAddrIn_t sLocalAddr ; int iCounter ; int iAddrSize ; int iSockID ; int iStatus ; int iNewSockID ; long lNonBlocking = 1 ; int iTestBufLen ; for ( iCounter = 0 ; iCounter < BUF_SIZE ; iCounter ++ ) { g_cBsdBuf [ iCounter ] = ( char ) ( iCo... | <S2SV_ModStart> = 0 ; # ifdef DEBUG <S2SV_ModStart> "Creating<S2SV_blank>socket" ) ; # endif <S2SV_ModStart> ) ; } # ifdef DEBUG <S2SV_ModStart> "Listening" ) ; # endif <S2SV_ModStart> ) ; } # ifdef DEBUG <S2SV_ModStart> "Nonblocking" ) ; # endif <S2SV_ModStart> 0 ) { # ifdef DEBUG <S2SV_ModStart> "Waiting<S2SV_blank>t... |
2,564 | CWE-000 void renameFile ( ) { if ( strlen ( fileName ) == 0 ) return ; if ( strcmp ( copyFrom , "" ) == 0 ) { if ( strcmp ( fileName , "." ) == 0 ) return ; if ( strcmp ( fileName , ".." ) == 0 ) <S2SV_StartBug> return ; <S2SV_EndBug> DRAGON_chdir ( curDir ) ; if ( dir_create ) DRAGON_mkdir ( fileName ) ; else { if ( d... | <S2SV_ModStart> 0 ) return <S2SV_ModEnd> ; if ( |
2,565 | CWE-000 <S2SV_StartBug> struct net_buf * bt_mesh_adv_create_from_pool ( struct net_buf_pool * pool , <S2SV_EndBug> enum bt_mesh_adv_type type , u8_t xmit_count , u8_t xmit_int , s32_t timeout ) { struct bt_mesh_adv * adv ; struct net_buf * buf ; buf = net_buf_alloc ( pool , timeout ) ; if ( ! buf ) { return NULL ; } <S... | <S2SV_ModStart> net_buf_pool * pool , bt_mesh_adv_alloc_t get_id <S2SV_ModStart> } adv = get_id ( net_buf_id <S2SV_ModEnd> ( buf ) <S2SV_ModStart> ( buf ) ) ; BT_MESH_ADV ( buf ) = adv |
2,566 | CWE-000 struct CoreError itp_compileProgram ( struct Core * core , const char * sourceCode ) { struct Interpreter * interpreter = core -> interpreter ; itp_freeProgram ( core ) ; interpreter -> sourceCode = uppercaseString ( sourceCode ) ; if ( ! interpreter -> sourceCode ) return err_makeCoreError ( ErrorOutOfMemory ,... | <S2SV_ModStart> -> labelStackItems [ interpreter -> numLabelStackItems - 1 <S2SV_ModEnd> ] ; switch |
2,567 | CWE-000 static void check_actions_for ( xmlNode * rsc_entry , resource_t * rsc , node_t * node , pe_working_set_t * data_set ) { GListPtr gIter = NULL ; int offset = - 1 ; int interval = 0 ; int stop_index = 0 ; int start_index = 0 ; const char * task = NULL ; const char * interval_s = NULL ; xmlNode * rsc_op = NULL ; ... | <S2SV_ModStart> pe_action_runnable ) ; crm_notice ( "Clearing<S2SV_blank>failure<S2SV_blank>of<S2SV_blank>%s<S2SV_blank>on<S2SV_blank>%s<S2SV_blank>" "because<S2SV_blank>action<S2SV_blank>definition<S2SV_blank>changed<S2SV_blank>" CRM_XS "<S2SV_blank>%s" , rsc -> id , node -> details -> uname , action_clear -> uuid ) ; |
2,568 | CWE-000 static ssize_t wcnss_ctrl_read ( struct file * fp , char __user * user_buffer , size_t count , loff_t * position ) { int rc = 0 ; <S2SV_StartBug> if ( ! penv || ! penv -> device_opened ) <S2SV_EndBug> return - EFAULT ; rc = wait_event_interruptible ( penv -> wlan_config . wcnss_ctrl_wait , ( penv -> wlan_config... | <S2SV_ModStart> ( ! penv <S2SV_ModEnd> ) return - |
2,569 | CWE-000 <S2SV_StartBug> void addBlock ( VA * address , int size , int offset ) <S2SV_EndBug> { struct block * newBlock ; newBlock = createBlock ( address , size , offset ) ; if ( Manager -> blocks == NULL ) { Manager -> blocks = newBlock ; return ; } struct block * curBlock = Manager -> blocks ; while ( curBlock != NUL... | <S2SV_ModStart> addBlock ( VA <S2SV_ModEnd> address , int <S2SV_ModStart> next ; } return ; |
2,570 | CWE-000 CURLcode Curl_http_auth_act ( struct connectdata * conn ) { struct Curl_easy * data = conn -> data ; bool pickhost = FALSE ; bool pickproxy = FALSE ; CURLcode result = CURLE_OK ; unsigned long authmask = ~ 0ul ; if ( ! conn -> oauth_bearer ) authmask &= ( unsigned long ) ~ CURLAUTH_BEARER ; if ( 100 <= data -> ... | <S2SV_ModStart> pickproxy ) { <S2SV_ModEnd> if ( ( <S2SV_ModStart> result ; } Curl_safefree ( data -> req . newurl ) ; data -> req . newurl = strdup ( data -> change . url ) ; if ( ! data -> req . newurl ) return CURLE_OUT_OF_MEMORY ; |
2,571 | CWE-000 <S2SV_StartBug> int _impl_k_queue_alloc_prepend ( struct k_queue * queue , void * data ) <S2SV_EndBug> { return queue_insert ( queue , NULL , data , true ) ; } | <S2SV_ModStart> <S2SV_null> <S2SV_null> <S2SV_null> s32_t <S2SV_ModEnd> _impl_k_queue_alloc_prepend ( struct |
2,572 | CWE-000 static void gschem_page_view_init ( GschemPageView * view ) { g_return_if_fail ( view != NULL ) ; view -> hadjustment = NULL ; view -> vadjustment = NULL ; geometry_cache_create ( view ) ; <S2SV_StartBug> view -> page = NULL ; <S2SV_EndBug> view -> configured = FALSE ; view -> doing_pan = FALSE ; view -> pan_x ... | <S2SV_ModStart> ; view -> _page <S2SV_ModEnd> = NULL ; |
2,573 | CWE-000 Obj DiffMat8BitMat8Bit ( Obj ml , Obj mr ) { Obj diff ; UInt q ; UInt i ; Obj row ; Obj type ; Obj info ; FF f ; FFV minusOne ; Obj mone ; UInt ll , lr , wl , wr , ld ; ll = LEN_MAT8BIT ( ml ) ; lr = LEN_MAT8BIT ( mr ) ; <S2SV_StartBug> wl = LEN_MAT8BIT ( ELM_MAT8BIT ( ml , 1 ) ) ; <S2SV_EndBug> wr = LEN_MAT8BI... | <S2SV_ModStart> ; wl = LEN_VEC8BIT ( ELM_MAT8BIT ( ml , 1 ) ) ; wr = LEN_VEC8BIT <S2SV_ModEnd> ( ELM_MAT8BIT ( |
2,574 | CWE-000 void log_config_init ( char * config_file ) { if ( NULL == g_log_config_handler ) { g_log_config_handler = ( stLogConfig * ) malloc ( sizeof ( stLogConfig ) ) ; if ( NULL == g_log_config_handler ) { fprintf ( stderr , "log<S2SV_blank>handler<S2SV_blank>malloc<S2SV_blank>error!\\n" ) ; return ; } <S2SV_StartBug>... | <S2SV_ModStart> return ; } <S2SV_ModEnd> if ( NULL <S2SV_ModStart> ) ; } } |
2,575 | CWE-000 void vim_beep ( unsigned val ) { # ifdef FEAT_EVAL called_vim_beep = TRUE ; # endif if ( emsg_silent == 0 ) { if ( ! ( ( bo_flags & val ) || ( bo_flags & BO_ALL ) ) ) { # ifdef ELAPSED_FUNC static int did_init = FALSE ; static ELAPSED_TYPE start_tv ; if ( ! did_init || ELAPSED_FUNC ( start_tv ) > 500 ) { did_in... | <S2SV_ModStart> # endif ) { <S2SV_ModStart> T_VB ) ; # ifdef FEAT_VTP if ( has_vtp_working ( ) != 0 # ifdef FEAT_TERMGUICOLORS && p_tgc # endif ) { redraw_later ( CLEAR ) ; update_screen ( 0 ) ; redrawcmd ( ) ; } # endif } |
2,576 | CWE-000 static void dnsout_send_notify ( zone_type * z , names_view_type view ) { <S2SV_StartBug> rrset_type * rrset = NULL ; <S2SV_EndBug> ldns_rr * soa = NULL ; if ( ! z -> notify ) { ods_log_error ( "[%s]<S2SV_blank>unable<S2SV_blank>to<S2SV_blank>send<S2SV_blank>notify<S2SV_blank>for<S2SV_blank>zone<S2SV_blank>%s:<... | <S2SV_ModStart> view ) { <S2SV_ModEnd> ldns_rr * soa <S2SV_ModStart> name ) ; names_viewlookupone ( view , NULL <S2SV_ModEnd> , LDNS_RR_TYPE_SOA , <S2SV_ModStart> LDNS_RR_TYPE_SOA , NULL , & soa <S2SV_ModStart> ; ods_log_assert ( soa <S2SV_ModEnd> ) ; soa <S2SV_ModStart> = ldns_rr_clone ( soa <S2SV_ModEnd> ) ; notify_e... |
2,577 | CWE-000 int main ( int argc , char * argv [ ] ) { int status = 0 ; BOOL abort = FALSE ; uint8_t index = 0 ; printf ( "\\n%s\\n" , MAIN_PROG_NAME ) ; <S2SV_StartBug> printf ( "Version:<S2SV_blank>%s\\n" , VERSION ) ; <S2SV_EndBug> printf ( "%s\\n\\n" , MAIN_COPYRIGHT ) ; if ( MAIN_RET_OK != main_init ( ) ) { abort = TRU... | <S2SV_ModStart> ; printf ( "Version:<S2SV_blank>%s<S2SV_blank>(%s)\\n" , VERSION , BUILDTYPE <S2SV_ModEnd> ) ; printf |
2,578 | CWE-000 void param_expension ( char * * value , t_params * params ) { char * ptr ; int state ; if ( ! value || ! * value ) return ; ptr = * value ; state = 0 ; while ( * ptr ) { printf ( "in<S2SV_blank>while<S2SV_blank>char:%c\\t%d\\t%p\\t%d\\n" , * ptr , * ptr , ptr , state ) ; if ( * ptr == '\\\\' ) { <S2SV_StartBug>... | <S2SV_ModStart> ) { ptr += 2 <S2SV_ModEnd> ; } else |
2,579 | CWE-000 <S2SV_StartBug> struct dentry * ovl_lookup_temp ( struct dentry * workdir , struct dentry * dentry ) <S2SV_EndBug> { struct dentry * temp ; char name [ 20 ] ; static atomic_t temp_id = ATOMIC_INIT ( 0 ) ; snprintf ( name , sizeof ( name ) , "#%x" , atomic_inc_return ( & temp_id ) ) ; temp = lookup_one_len ( nam... | <S2SV_ModStart> dentry * workdir <S2SV_ModEnd> ) { struct |
2,580 | CWE-000 <S2SV_StartBug> void particles_indices ( int grid [ 3 ] ) { <S2SV_EndBug> if ( particles_gentype == PARTICLES_GT_QUEUE ) { grid [ 0 ] = particles_g_r - 1 ; grid [ 1 ] = particles_g_param1 - 1 ; grid [ 2 ] = particles_g_param2 - 1 ; } else { grid [ 0 ] = particles_r - 1 ; grid [ 1 ] = particles_param1 - 1 ; grid... | <S2SV_ModStart> 3 ] ) <S2SV_ModEnd> { grid [ <S2SV_ModStart> - 1 ; <S2SV_ModEnd> if ( grid |
2,581 | CWE-000 char * getLineSeparator ( gameParams * game ) { char * separator ; int N , m , i ; m = game -> m ; N = game -> N ; separator = malloc ( sizeof ( char ) * ( 4 * N + m + 1 ) + 1 ) ; if ( separator == NULL ) { freeSudokuGame ( game ) ; printMallocFailed ( ) ; <S2SV_StartBug> exit ( EXIT_FAILURE ) ; <S2SV_EndBug> }... | <S2SV_ModStart> ; exit ( 0 <S2SV_ModEnd> ) ; } |
2,582 | CWE-000 __attribute__ ( ( nonnull ( 1 , 2 ) , nothrow , warn_unused_result ) ) static int removes_front_test ( darr_t * restrict darr , int nums [ ] , size_t nnum ) { int * restrict tmps ; <S2SV_StartBug> printf ( "removes<S2SV_blank>front<S2SV_blank>test<S2SV_blank>(nnum=%d)\\n" , ( int ) nnum ) ; <S2SV_EndBug> tmps =... | <S2SV_ModStart> int ) nnum ) ; fflush ( stdout |
2,583 | CWE-000 void * shoes_native_menu_new ( shoes_menu * mn ) { GtkWidget * menu ; GtkWidget * mi ; menu = gtk_menu_new ( ) ; mi = gtk_menu_item_new_with_label ( mn -> title ) ; gtk_menu_item_set_submenu ( GTK_MENU_ITEM ( mi ) , menu ) ; mn -> native = ( void * ) mi ; mn -> extra = ( void * ) menu ; <S2SV_StartBug> } <S2SV_... | <S2SV_ModStart> ) menu ; return mn -> native ; |
2,584 | CWE-000 void sqlite3GenerateRowDelete ( <S2SV_StartBug> Parse * pParse , <S2SV_EndBug> Table * pTab , Trigger * pTrigger , int iDataCur , int iIdxCur , int iPk , i16 nPk , u8 count , u8 onconf , u8 eMode , int iIdxNoSeek ) { Vdbe * v = pParse -> pVdbe ; int iOld = 0 ; int iLabel ; u8 opSeek ; assert ( v ) ; VdbeModuleC... | <S2SV_ModStart> Parse * pParse , int iDb <S2SV_ModStart> ( pParse , iDb , <S2SV_ModStart> ( pParse , iDb , <S2SV_ModStart> ( pParse , iDb , <S2SV_ModStart> ( pParse , iDb , |
2,585 | CWE-000 void scale_bilinear_prepare ( unsigned char * ( * index ) ( const struct imagebuffer * image , size_t x , size_t y ) , unsigned char * restrict out_x0y0 , unsigned char * restrict out_x0y1 , unsigned char * restrict out_x1y0 , unsigned char * restrict out_x1y1 , size_t * restrict out_xf , size_t * restrict out_... | <S2SV_ModStart> = ( * index <S2SV_ModEnd> ( src , <S2SV_ModStart> = ( * index <S2SV_ModEnd> ( src , <S2SV_ModStart> = ( * index <S2SV_ModEnd> ( src , <S2SV_ModStart> = ( * index <S2SV_ModEnd> ( src , |
2,586 | CWE-000 int fill_square ( t_square * solution_square , t_tetralist * complete_list ) { int i ; int j ; if ( complete_list == NULL ) return ( 1 ) ; i = 0 ; while ( i < solution_square -> size ) { j = 0 ; while ( j < solution_square -> size ) { if ( place_tetra ( solution_square , complete_list , i , j ) ) { <S2SV_StartB... | <S2SV_ModStart> { if ( fill_square <S2SV_ModEnd> ( solution_square , |
2,587 | CWE-000 int local_edit_distance ( const Py_UNICODE * s , size_t ss , const Py_UNICODE * t , size_t st , <S2SV_StartBug> int match , int mismatch , int gap <S2SV_EndBug> ) { size_t rows = st + 1 ; size_t cols = ss + 1 ; int d1 , d2 , d3 ; unsigned short is_distance = match < mismatch ? 1 : 0 ; int * dp = malloc ( rows *... | <S2SV_ModStart> mismatch , int insert , int delete <S2SV_ModEnd> ) { size_t <S2SV_ModStart> cols ] = 0 <S2SV_ModEnd> ; } for <S2SV_ModStart> = i * 0 <S2SV_ModEnd> ; } for <S2SV_ModStart> 1 ] + delete <S2SV_ModEnd> ; d2 = <S2SV_ModStart> k ] + insert <S2SV_ModEnd> ; if ( |
2,588 | CWE-000 struct request * nvme_alloc_request ( struct request_queue * q , struct nvme_command * cmd , blk_mq_req_flags_t flags , int qid ) { unsigned op = nvme_is_write ( cmd ) ? REQ_OP_DRV_OUT : REQ_OP_DRV_IN ; struct request * req ; if ( qid == NVME_QID_ANY ) { req = blk_mq_alloc_request ( q , op , flags ) ; } else { ... | <S2SV_ModStart> |= REQ_FAILFAST_DRIVER ; nvme_clear_nvme_request ( req ) ; |
2,589 | CWE-000 ngx_int_t ngx_http_php_content_post_handler ( ngx_http_request_t * r ) { TSRMLS_FETCH ( ) ; ngx_http_php_main_conf_t * pmcf = ngx_http_get_module_main_conf ( r , ngx_http_php_module ) ; ngx_http_php_loc_conf_t * plcf = ngx_http_get_module_loc_conf ( r , ngx_http_php_module ) ; ngx_int_t rc ; ngx_http_php_ctx_t ... | <S2SV_ModStart> rc ; } NGX_HTTP_PHP_R_INIT ( r ) ; |
2,590 | CWE-000 static char * prepare ( char * fields [ 10 ] , struct fmt_main * self ) { static char Buf [ 256 ] ; char tmp [ 512 ] , tmp2 [ 512 ] , tmp4 [ 256 ] , tmp5 [ 6 ] , tmp6 [ 6 ] , * cp , * cp2 ; int N , r , p ; if ( ! strncmp ( fields [ 1 ] , FMT_CISCO9 , FMT_CISCO9_LEN ) ) { if ( strlen ( fields [ 1 ] ) != 4 + 14 +... | <S2SV_ModStart> = 0 ; snprintf ( Buf , sizeof ( Buf ) <S2SV_ModEnd> , "%s%c%s%s%14.14s$%s" , <S2SV_ModStart> [ strlen ( tmp4 <S2SV_ModEnd> ) - 1 <S2SV_ModStart> = 0 ; snprintf ( Buf , sizeof ( Buf ) <S2SV_ModEnd> , "%s%c%s%s%s$%s" , |
2,591 | CWE-000 static ssize_t kcal_min_store ( struct device * dev , struct device_attribute * attr , const char * buf , size_t count ) { int kcal_min , r ; struct kcal_lut_data * lut_data = dev_get_drvdata ( dev ) ; r = kstrtoint ( buf , 10 , & kcal_min ) ; <S2SV_StartBug> if ( ( r ) || ( kcal_min < 1 || kcal_min > 256 ) ) <... | <S2SV_ModStart> ( kcal_min < 0 <S2SV_ModEnd> || kcal_min > |
2,592 | CWE-000 static void power_down_all_systems ( void ) { nrf_gpio_cfg_output ( 15 ) ; <S2SV_StartBug> nrf_gpio_cfg_output ( 16 ) ; <S2SV_EndBug> nrf_gpio_cfg_output ( IC_LTC_POWER_PIN ) ; <S2SV_StartBug> nrf_gpio_pin_clear ( 15 ) ; <S2SV_EndBug> nrf_gpio_pin_clear ( 16 ) ; nrf_gpio_pin_clear ( IC_LTC_POWER_PIN ) ; nrf_gpi... | <S2SV_ModStart> 15 ) ; nrf_gpio_pin_clear ( 15 ) ; nrf_gpio_cfg_output ( 16 ) ; nrf_gpio_pin_clear <S2SV_ModEnd> ( 16 ) <S2SV_ModStart> ; nrf_gpio_pin_clear ( IC_LTC_POWER_PIN <S2SV_ModEnd> ) ; } |
2,593 | CWE-000 void moveTo ( int distance , int direction ) { float totalPulses = ( distance / 1.38 ) ; uint16_t speed = 1700 ; int partitialError = 0 ; int derivativeError = 0 ; int integralError = 0 ; int referenceValue = 0 ; int measurementValue ; int controlValue ; int iPart = 0 ; int dPart = 0 ; int kp = 20 ; int kd = 2 ... | <S2SV_ModStart> = 0 ; <S2SV_ModEnd> reset_Counter ( ) <S2SV_ModStart> 1 ; } <S2SV_ModEnd> while ( totMovement <S2SV_ModStart> ) ; } <S2SV_ModEnd> } rightWheel ( |
2,594 | CWE-000 static int aiv_gb_opcode_b6 ( aiv_gameboy * gb ) { <S2SV_StartBug> gb -> a | gb -> hl ; <S2SV_EndBug> if ( gb -> a == 0 ) { SET_Z ( gb ) ; <S2SV_StartBug> UNSET_N ( gb ) ; <S2SV_EndBug> UNSET_H ( gb ) ; UNSET_C ( gb ) ; } else { <S2SV_StartBug> UNSET_Z ( gb ) ; <S2SV_EndBug> UNSET_N ( gb ) ; UNSET_H ( gb ) ; UN... | <S2SV_ModStart> gb -> a |= <S2SV_ModEnd> gb -> hl <S2SV_ModStart> gb ) ; <S2SV_ModEnd> } else { <S2SV_ModStart> gb ) ; } <S2SV_ModStart> gb ) ; <S2SV_ModEnd> return 8 ; |
2,595 | CWE-000 static void scheduler_timer ( void * data , const struct isr_regs * regs ) { assert ( current_task ) ; save_task_state ( current_task , regs ) ; <S2SV_StartBug> if ( current_task != idle_task ) { <S2SV_EndBug> checked_lock ( & ready_queue_lock ) ; list_append ( & ready_queue , current_task , node ) ; checked_un... | <S2SV_ModStart> regs ) ; scheduler_perform_checks ( ) ; |
2,596 | CWE-000 <S2SV_StartBug> void printLab ( LabCell lab ) { <S2SV_EndBug> int i = 0 ; int j = 0 ; <S2SV_StartBug> while ( i < lab . maxrow + 1 ) { <S2SV_EndBug> <S2SV_StartBug> printf ( "%s" , lab . lab [ i ] ) ; <S2SV_EndBug> i ++ ; } } | <S2SV_ModStart> void printLab ( char lab [ ] [ MAXROWS ] , int maxRow <S2SV_ModEnd> ) { int <S2SV_ModStart> ( i < maxRow <S2SV_ModEnd> + 1 ) <S2SV_ModStart> { printf ( "%s\\n" , <S2SV_ModEnd> lab [ i |
2,597 | CWE-000 static int init ( ) { int sockfd ; struct sockaddr_in my_name ; int status ; sockfd = socket ( AF_INET , SOCK_DGRAM , 0 ) ; if ( sockfd == - 1 ) { perror ( "Socket<S2SV_blank>creation<S2SV_blank>error" ) ; goto error ; } my_name . sin_family = AF_INET ; <S2SV_StartBug> my_name . sin_addr . s_addr = INADDR_ANY ;... | <S2SV_ModStart> = AF_INET ; inet_aton ( UDP_SERVER_ADDR , <S2SV_ModStart> sin_addr . s_addr ) <S2SV_ModEnd> ; my_name . |
2,598 | CWE-000 static gboolean commit_changes ( NMSettingsConnection * connection , <S2SV_StartBug> NMSettingsConnectionCommitReason commit_reason , <S2SV_EndBug> GError * * error ) { NMIfnetConnectionPrivate * priv = NM_IFNET_CONNECTION_GET_PRIVATE ( ( NMIfnetConnection * ) connection ) ; char * new_name = NULL ; gboolean su... | <S2SV_ModStart> * connection , NMConnection * new_connection , NMSettingsConnectionCommitReason commit_reason , NMConnection * * out_reread_connection , char * * out_logmsg_change <S2SV_ModEnd> , GError * |
2,599 | CWE-000 void sort_arr ( List * processes ) { int size = processes -> size ; if ( size <= 1 ) return ; elem * e ; char sorted = 0 ; while ( ! sorted ) { sorted = 1 ; e = processes -> first ; <S2SV_StartBug> for ( int i = 0 ; i < -- size ; i ++ ) { <S2SV_EndBug> if ( e -> proc . t_arr > e -> next -> proc . t_arr ) { swit... | <S2SV_ModStart> -> first ; size -- ; <S2SV_ModStart> ; i < <S2SV_ModEnd> size ; i |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.